dash0

package module
v1.8.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2026 License: Apache-2.0 Imports: 19 Imported by: 1

README

Dash0 Go API Client GoDoc

A Go client library for the Dash0 API.

Requirements

Go 1.25 or later.

Installation

go get github.com/dash0hq/dash0-api-client-go

Usage

package main

import (
    "context"
    "fmt"
    "log"

    "github.com/dash0hq/dash0-api-client-go"
)

func main() {
    // Create a new client
    client, err := dash0.NewClient(
        dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
        dash0.WithAuthToken("auth_your-auth-token"),
    )
    if err != nil {
        log.Fatal(err)
    }
    defer client.Close(context.Background())

    // List dashboards in the "default" dataset
    dashboards, err := client.ListDashboards(context.Background(), dash0.String("default"))
    if err != nil {
        if dash0.IsUnauthorized(err) {
            log.Fatal("Invalid API token")
        }
        log.Fatal(err)
    }

    for _, d := range dashboards {
        fmt.Printf("Dashboard: %s (ID: %s)\n", d.Name, d.Id)
    }
}

Sending Telemetry Data (OTLP)

The client can push OpenTelemetry traces, metrics, and logs to an OTLP endpoint with otlp/json encoding. You can create a client with only an OTLP endpoint, only a REST API URL, or both:

// OTLP-only client (no REST API access)
client, err := dash0.NewClient(
    dash0.WithAuthToken("auth_your-auth-token"),
    dash0.WithOtlpEndpoint(dash0.OtlpEncodingJson, "https://otlp.eu-west-1.aws.dash0.com"),
)

// Combined client (REST API + OTLP)
client, err := dash0.NewClient(
    dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
    dash0.WithAuthToken("auth_your-auth-token"),
    dash0.WithOtlpEndpoint(dash0.OtlpEncodingJson, "https://otlp.eu-west-1.aws.dash0.com"),
)

The SendTraces, SendMetrics, and SendLogs methods accept pdata types (ptrace.Traces, pmetric.Metrics, plog.Logs). Signal-specific paths (/v1/traces, /v1/metrics, /v1/logs) are appended automatically to the base endpoint URL. Pass nil as the dataset to send data to the default dataset in Dash0.

// Send to the default dataset
err = client.SendTraces(ctx, traces, nil)
err = client.SendMetrics(ctx, metrics, nil)
err = client.SendLogs(ctx, logs, nil)

// Send to a specific dataset
err = client.SendTraces(ctx, traces, dash0.String("my-dataset"))
err = client.SendMetrics(ctx, metrics, dash0.String("my-dataset"))
err = client.SendLogs(ctx, logs, dash0.String("my-dataset"))

OTLP requests use the same HTTP client, retry logic, and rate limiting as the REST API calls. Call Close when the underlying HTTP client is no longer needed.

Configuration Options

Option Description Default
WithApiUrl(url) Dash0 API URL (required for REST API) -
WithAuthToken(token) Auth token for authentication (required) -
WithOtlpEndpoint(enc, url) OTLP/HTTP endpoint for telemetry push (required for OTLP) -
WithMaxConcurrentRequests(n) Maximum concurrent API requests (1-10) 3
WithTimeout(duration) HTTP request timeout 30s
WithHTTPClient(client) Custom HTTP client -
WithUserAgent(ua) Custom User-Agent header dash0-api-client-go/<version>
WithMaxRetries(n) Maximum retries for failed requests (0-5) 1
WithRetryWaitMin(duration) Minimum wait between retries 500ms
WithRetryWaitMax(duration) Maximum wait between retries 30s

NewClient requires WithAuthToken and at least one of WithApiUrl or WithOtlpEndpoint. REST API methods (dashboards, check rules, etc.) require WithApiUrl; OTLP methods (SendTraces, SendMetrics, SendLogs) require WithOtlpEndpoint. Calling a method whose endpoint was not configured returns an error.

Automatic Retries

The client automatically retries failed requests with exponential backoff:

  • Retried errors: 429 (rate limited) and 5xx (server errors)
  • Max retries: 1 (configurable up to 5 via WithMaxRetries)
  • Backoff: Exponential with jitter, starting at 500ms up to 30s
  • Retry-After: Respected when present in response headers

Only idempotent requests (GET, PUT, DELETE, HEAD, OPTIONS) and OTLP sends are retried automatically.

Pagination with Iterators

For endpoints that return paginated results, use iterators to automatically fetch all pages:

// Iterate over all spans in a time range
iter := client.GetSpansIter(ctx, &dash0.GetSpansRequest{
    TimeRange: dash0.TimeReferenceRange{
        From: "now-1h",
        To:   "now",
    },
})

for iter.Next() {
    resourceSpan := iter.Current()
    // process resourceSpan
}
if err := iter.Err(); err != nil {
    log.Fatal(err)
}

Error Handling

HTTP errors

Both REST API and OTLP methods return *dash0.APIError for non-2xx HTTP responses. The error includes the status code, message, and trace ID for support:

err := client.SendTraces(ctx, traces, nil)
if err != nil {
    if apiErr, ok := err.(*dash0.APIError); ok {
        fmt.Printf("API error: %s (status: %d, trace_id: %s)\n",
            apiErr.Message, apiErr.StatusCode, apiErr.TraceID)
    }
}

The same helper functions work for both REST API and OTLP errors:

if dash0.IsUnauthorized(err) {
    // Handle 401 - invalid or expired token
}
if dash0.IsRateLimited(err) {
    // Handle 429 - too many requests
}
if dash0.IsServerError(err) {
    // Handle 5xx - server errors
}
if dash0.IsNotFound(err) {
    // Handle 404
}
if dash0.IsForbidden(err) {
    // Handle 403 - insufficient permissions
}
if dash0.IsBadRequest(err) {
    // Handle 400 - invalid request
}
if dash0.IsConflict(err) {
    // Handle 409 - resource conflict
}
Not-configured errors

Calling a method whose endpoint was not configured returns a sentinel error that can be checked with errors.Is:

if errors.Is(err, dash0.ErrOTLPNotConfigured) {
    // SendTraces/SendMetrics/SendLogs called without WithOtlpEndpoint
}
if errors.Is(err, dash0.ErrAPINotConfigured) {
    // REST API method called without WithApiUrl
}

Testing

The dash0.Client is an interface, making it easy to mock in tests. Use dash0test.MockClient for a ready-to-use mock implementation:

package mypackage

import (
    "context"
    "testing"

    "github.com/dash0hq/dash0-api-client-go"
    "github.com/dash0hq/dash0-api-client-go/dash0test"
)

// MyService uses the Dash0 client
type MyService struct {
    client dash0.Client
}

func TestMyService(t *testing.T) {
    // Create a mock client with custom behavior
    mock := &dash0test.MockClient{
        ListDashboardsFunc: func(ctx context.Context, dataset *string) ([]*dash0.DashboardApiListItem, error) {
            return []*dash0.DashboardApiListItem{
                {Id: dash0.Ptr("dashboard-1"), Name: dash0.Ptr("My Dashboard")},
            }, nil
        },
    }

    // Inject the mock into your service
    svc := &MyService{client: mock}

    // Test your service...
    _ = svc
}

License

See LICENSE for details.

Documentation

Overview

Package dash0 provides a high-level client for the Dash0 API.

Package dash0 provides primitives to interact with the openapi HTTP API.

Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.5.1 DO NOT EDIT.

Index

Examples

Constants

View Source
const (
	AnnotationFolderPath = "dash0.com/folder-path"
	AnnotationSharing    = "dash0.com/sharing"
	AnnotationSource     = "dash0.com/source"
)

CRD annotation keys used by Dash0 assets in Kubernetes-style metadata.

View Source
const (
	// DefaultMaxConcurrentRequests is the default maximum number of concurrent API requests.
	DefaultMaxConcurrentRequests = 3

	// MaxConcurrentRequests is the maximum allowed value for concurrent requests.
	MaxConcurrentRequests = 10

	// DefaultTimeout is the default HTTP request timeout.
	DefaultTimeout = 30 * time.Second

	// DefaultUserAgent is the default User-Agent header value.
	DefaultUserAgent = "dash0-api-client-go/" + Version

	// DefaultRetryWaitMin is the default minimum wait time between retries.
	DefaultRetryWaitMin = 500 * time.Millisecond

	// DefaultRetryWaitMax is the default maximum wait time between retries.
	DefaultRetryWaitMax = 30 * time.Second

	// MaxRetries is the maximum allowed number of retries.
	MaxRetries = 5
)
View Source
const (
	LabelID      = "dash0.com/id"
	LabelDataset = "dash0.com/dataset"
	LabelOrigin  = "dash0.com/origin"
)

CRD label keys used by Dash0 assets in Kubernetes-style metadata.

Deprecated: since v1.6.0. Use DashboardSourceApi instead.

Deprecated: since v1.6.0. Use DashboardSourceOperator instead.

Deprecated: since v1.6.0. Use DashboardSourceTerraform instead.

Deprecated: since v1.6.0. Use DashboardSourceUi instead.

View Source
const Version = "1.8.0"

Version is the version of the dash0-api-client-go library. Updated automatically by the release workflow.

Variables

View Source
var ErrAPINotConfigured = errors.New("dash0: API endpoint not configured (use WithApiUrl)")

ErrAPINotConfigured is returned when a REST API method is called on a client created without WithApiUrl.

View Source
var ErrOTLPNotConfigured = errors.New("dash0: OTLP endpoint not configured (use WithOtlpEndpoint)")

ErrOTLPNotConfigured is returned when SendTraces, SendMetrics, or SendLogs is called on a client created without WithOtlpEndpoint.

Functions

func Bool

func Bool(v bool) *bool

Bool returns a pointer to the given bool value.

func BoolValue

func BoolValue(p *bool) bool

BoolValue returns the value of a bool pointer, or false if nil.

func ClearCheckRuleID added in v1.6.0

func ClearCheckRuleID(rule *PrometheusAlertRule)

ClearCheckRuleID removes the ID from a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Id: dash0.Ptr("cr-42")}
	dash0.ClearCheckRuleID(rule)
	fmt.Println(rule.Id == nil)
}
Output:
true

func ClearDashboardID added in v1.6.0

func ClearDashboardID(dashboard *DashboardDefinition)

ClearDashboardID removes the ID from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Dash0Extensions: &dash0.DashboardMetadataExtensions{
				Id: dash0.Ptr("d-123"),
			},
		},
	}
	dash0.ClearDashboardID(dashboard)
	fmt.Println(dashboard.Metadata.Dash0Extensions.Id == nil)
}
Output:
true

func ClearPersesDashboardID added in v1.6.0

func ClearPersesDashboardID(perses *PersesDashboard)

ClearPersesDashboardID removes the dash0.com/id label from a PersesDashboard CRD.

func ClearPrometheusRuleID added in v1.6.0

func ClearPrometheusRuleID(rule *PrometheusRules)

ClearPrometheusRuleID removes the dash0.com/id label from a PrometheusRules CRD.

func ClearSyntheticCheckID added in v1.6.0

func ClearSyntheticCheckID(check *SyntheticCheckDefinition)

ClearSyntheticCheckID removes the ID from a synthetic check definition.

func ClearViewID added in v1.6.0

func ClearViewID(view *ViewDefinition)

ClearViewID removes the ID from a view definition.

func DatasetPtr added in v1.6.0

func DatasetPtr(dataset string) *string

DatasetPtr converts a dataset string to a pointer, returning nil for empty strings and for "default" (the API uses "default" implicitly when no dataset parameter is sent).

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	// Returns nil for "default" — the API treats absent dataset as "default".
	p := dash0.DatasetPtr("default")
	fmt.Println(p)
}
Output:
<nil>
Example (NonDefault)
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	p := dash0.DatasetPtr("production")
	fmt.Println(*p)
}
Output:
production

func Float64

func Float64(v float64) *float64

Float64 returns a pointer to the given float64 value.

func Float64Value

func Float64Value(p *float64) float64

Float64Value returns the value of a float64 pointer, or 0 if nil.

func FormatDuration added in v1.6.0

func FormatDuration(d time.Duration) string

FormatDuration formats a time.Duration as a compact Prometheus-style duration string (e.g., "2m" instead of Go's "2m0s").

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	fmt.Println(dash0.FormatDuration(5 * 60e9))   // 5 minutes
	fmt.Println(dash0.FormatDuration(90e9))       // 1m30s
	fmt.Println(dash0.FormatDuration(2 * 3600e9)) // 2 hours
}
Output:
5m
1m30s
2h

func GetCheckRuleDataset added in v1.6.0

func GetCheckRuleDataset(rule *PrometheusAlertRule) string

GetCheckRuleDataset extracts the dataset from a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Dataset: dash0.Ptr("production")}
	fmt.Println(dash0.GetCheckRuleDataset(rule))
}
Output:
production

func GetCheckRuleID added in v1.6.0

func GetCheckRuleID(rule *PrometheusAlertRule) string

GetCheckRuleID extracts the ID from a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Id: dash0.Ptr("cr-42")}
	fmt.Println(dash0.GetCheckRuleID(rule))
}
Output:
cr-42

func GetCheckRuleName added in v1.6.0

func GetCheckRuleName(rule *PrometheusAlertRule) string

GetCheckRuleName extracts the name from a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Name: "HighErrorRate"}
	fmt.Println(dash0.GetCheckRuleName(rule))
}
Output:
HighErrorRate

func GetDashboardDataset added in v1.6.0

func GetDashboardDataset(dashboard *DashboardDefinition) string

GetDashboardDataset extracts the dataset from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Dash0Extensions: &dash0.DashboardMetadataExtensions{
				Dataset: dash0.Ptr("production"),
			},
		},
	}
	fmt.Println(dash0.GetDashboardDataset(dashboard))
}
Output:
production

func GetDashboardFolderPath added in v1.6.0

func GetDashboardFolderPath(dashboard *DashboardDefinition) string

GetDashboardFolderPath extracts the folder path from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Annotations: &dash0.DashboardAnnotations{
				Dash0ComfolderPath: dash0.Ptr("/team/sre"),
			},
		},
	}
	fmt.Println(dash0.GetDashboardFolderPath(dashboard))
}
Output:
/team/sre

func GetDashboardID added in v1.6.0

func GetDashboardID(dashboard *DashboardDefinition) string

GetDashboardID extracts the ID from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Dash0Extensions: &dash0.DashboardMetadataExtensions{
				Id: dash0.Ptr("d-123"),
			},
		},
	}
	fmt.Println(dash0.GetDashboardID(dashboard))
}
Output:
d-123

func GetDashboardName added in v1.6.0

func GetDashboardName(dashboard *DashboardDefinition) string

GetDashboardName extracts the display name from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Spec: map[string]any{
			"display": map[string]any{"name": "API Latency"},
		},
	}
	fmt.Println(dash0.GetDashboardName(dashboard))
}
Output:
API Latency

func GetPersesDashboardDataset added in v1.6.0

func GetPersesDashboardDataset(perses *PersesDashboard) string

GetPersesDashboardDataset returns the dash0.com/dataset label value if present.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	perses := &dash0.PersesDashboard{
		Metadata: dash0.PersesDashboardMetadata{
			Labels: map[string]string{"dash0.com/dataset": "production"},
		},
	}
	fmt.Println(dash0.GetPersesDashboardDataset(perses))
}
Output:
production

func GetPersesDashboardFolderPath added in v1.6.0

func GetPersesDashboardFolderPath(perses *PersesDashboard) string

GetPersesDashboardFolderPath returns the dash0.com/folder-path annotation value if present.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	perses := &dash0.PersesDashboard{
		Metadata: dash0.PersesDashboardMetadata{
			Annotations: map[string]string{dash0.AnnotationFolderPath: "/team/sre"},
		},
	}
	fmt.Println(dash0.GetPersesDashboardFolderPath(perses))
}
Output:
/team/sre

func GetPersesDashboardID added in v1.6.0

func GetPersesDashboardID(perses *PersesDashboard) string

GetPersesDashboardID returns the dash0.com/id label value if present.

func GetPersesDashboardName added in v1.6.0

func GetPersesDashboardName(perses *PersesDashboard) string

GetPersesDashboardName returns the display name from the Perses spec, falling back to metadata.name.

func GetPrometheusRuleDataset added in v1.6.0

func GetPrometheusRuleDataset(rule *PrometheusRules) string

GetPrometheusRuleDataset extracts the dataset from a PrometheusRules definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusRules{
		Metadata: dash0.PrometheusRulesMetadata{
			Labels: map[string]string{"dash0.com/dataset": "production"},
		},
	}
	fmt.Println(dash0.GetPrometheusRuleDataset(rule))
}
Output:
production

func GetPrometheusRuleID added in v1.6.0

func GetPrometheusRuleID(rule *PrometheusRules) string

GetPrometheusRuleID extracts the ID from a PrometheusRules definition.

func GetPrometheusRuleName added in v1.6.0

func GetPrometheusRuleName(rule *PrometheusRules) string

GetPrometheusRuleName extracts the name from a PrometheusRules definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusRules{
		Metadata: dash0.PrometheusRulesMetadata{Name: "my-rules"},
	}
	fmt.Println(dash0.GetPrometheusRuleName(rule))
}
Output:
my-rules

func GetSyntheticCheckDataset added in v1.6.0

func GetSyntheticCheckDataset(check *SyntheticCheckDefinition) string

GetSyntheticCheckDataset extracts the dataset from a synthetic check definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	check := &dash0.SyntheticCheckDefinition{
		Metadata: dash0.SyntheticCheckMetadata{
			Labels: &dash0.SyntheticCheckLabels{Dash0Comdataset: dash0.Ptr("production")},
		},
	}
	fmt.Println(dash0.GetSyntheticCheckDataset(check))
}
Output:
production

func GetSyntheticCheckID added in v1.6.0

func GetSyntheticCheckID(check *SyntheticCheckDefinition) string

GetSyntheticCheckID extracts the ID from a synthetic check definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	check := &dash0.SyntheticCheckDefinition{
		Metadata: dash0.SyntheticCheckMetadata{
			Labels: &dash0.SyntheticCheckLabels{Dash0Comid: dash0.Ptr("sc-7")},
		},
	}
	fmt.Println(dash0.GetSyntheticCheckID(check))
}
Output:
sc-7

func GetSyntheticCheckName added in v1.6.0

func GetSyntheticCheckName(check *SyntheticCheckDefinition) string

GetSyntheticCheckName extracts the display name from a synthetic check definition, falling back to metadata.name if no display name is set.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	check := &dash0.SyntheticCheckDefinition{
		Spec: dash0.SyntheticCheckSpec{
			Display: &dash0.SyntheticCheckDisplay{Name: "Homepage Ping"},
		},
	}
	fmt.Println(dash0.GetSyntheticCheckName(check))
}
Output:
Homepage Ping

func GetViewDataset added in v1.6.0

func GetViewDataset(view *ViewDefinition) string

GetViewDataset extracts the dataset from a view definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	view := &dash0.ViewDefinition{
		Metadata: dash0.ViewMetadata{
			Labels: &dash0.ViewLabels{Dash0Comdataset: dash0.Ptr("production")},
		},
	}
	fmt.Println(dash0.GetViewDataset(view))
}
Output:
production

func GetViewID added in v1.6.0

func GetViewID(view *ViewDefinition) string

GetViewID extracts the ID from a view definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	view := &dash0.ViewDefinition{
		Metadata: dash0.ViewMetadata{
			Labels: &dash0.ViewLabels{Dash0Comid: dash0.Ptr("v-99")},
		},
	}
	fmt.Println(dash0.GetViewID(view))
}
Output:
v-99

func GetViewName added in v1.6.0

func GetViewName(view *ViewDefinition) string

GetViewName extracts the display name from a view definition, falling back to metadata.name if the display name is empty.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	view := &dash0.ViewDefinition{
		Spec: dash0.ViewSpec{Display: dash0.ViewDisplay{Name: "Error Logs"}},
	}
	fmt.Println(dash0.GetViewName(view))
}
Output:
Error Logs
Example (Fallback)
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	// Falls back to metadata.name when no display name is set.
	view := &dash0.ViewDefinition{
		Metadata: dash0.ViewMetadata{Name: "error-logs"},
	}
	fmt.Println(dash0.GetViewName(view))
}
Output:
error-logs

func Int64

func Int64(v int64) *int64

Int64 returns a pointer to the given int64 value.

func Int64Value

func Int64Value(p *int64) int64

Int64Value returns the value of an int64 pointer, or 0 if nil.

func IsBadRequest

func IsBadRequest(err error) bool

IsBadRequest returns true if the error is a 400 Bad Request.

func IsConflict

func IsConflict(err error) bool

IsConflict returns true if the error is a 409 Conflict.

func IsForbidden

func IsForbidden(err error) bool

IsForbidden returns true if the error is a 403 Forbidden.

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns true if the error is a 404 Not Found.

func IsRateLimited

func IsRateLimited(err error) bool

IsRateLimited returns true if the error is a 429 Too Many Requests.

func IsServerError

func IsServerError(err error) bool

IsServerError returns true if the error is a 5xx server error.

func IsUnauthorized

func IsUnauthorized(err error) bool

IsUnauthorized returns true if the error is a 401 Unauthorized.

func NewDeleteApiAlertingCheckRulesOriginOrIdRequest

func NewDeleteApiAlertingCheckRulesOriginOrIdRequest(server string, originOrId string, params *DeleteApiAlertingCheckRulesOriginOrIdParams) (*http.Request, error)

NewDeleteApiAlertingCheckRulesOriginOrIdRequest generates requests for DeleteApiAlertingCheckRulesOriginOrId

func NewDeleteApiDashboardsOriginOrIdRequest

func NewDeleteApiDashboardsOriginOrIdRequest(server string, originOrId string, params *DeleteApiDashboardsOriginOrIdParams) (*http.Request, error)

NewDeleteApiDashboardsOriginOrIdRequest generates requests for DeleteApiDashboardsOriginOrId

func NewDeleteApiMembersMemberIDRequest added in v1.4.0

func NewDeleteApiMembersMemberIDRequest(server string, memberID string) (*http.Request, error)

NewDeleteApiMembersMemberIDRequest generates requests for DeleteApiMembersMemberID

func NewDeleteApiRecordingRuleGroupsOriginOrIdRequest added in v1.6.0

func NewDeleteApiRecordingRuleGroupsOriginOrIdRequest(server string, originOrId string, params *DeleteApiRecordingRuleGroupsOriginOrIdParams) (*http.Request, error)

NewDeleteApiRecordingRuleGroupsOriginOrIdRequest generates requests for DeleteApiRecordingRuleGroupsOriginOrId

func NewDeleteApiSamplingRulesOriginOrIdRequest added in v1.1.0

func NewDeleteApiSamplingRulesOriginOrIdRequest(server string, originOrId string, params *DeleteApiSamplingRulesOriginOrIdParams) (*http.Request, error)

NewDeleteApiSamplingRulesOriginOrIdRequest generates requests for DeleteApiSamplingRulesOriginOrId

func NewDeleteApiSyntheticChecksOriginOrIdRequest

func NewDeleteApiSyntheticChecksOriginOrIdRequest(server string, originOrId string, params *DeleteApiSyntheticChecksOriginOrIdParams) (*http.Request, error)

NewDeleteApiSyntheticChecksOriginOrIdRequest generates requests for DeleteApiSyntheticChecksOriginOrId

func NewDeleteApiTeamsOriginOrIdMembersMemberIDRequest added in v1.4.0

func NewDeleteApiTeamsOriginOrIdMembersMemberIDRequest(server string, originOrId string, memberID string) (*http.Request, error)

NewDeleteApiTeamsOriginOrIdMembersMemberIDRequest generates requests for DeleteApiTeamsOriginOrIdMembersMemberID

func NewDeleteApiTeamsOriginOrIdRequest added in v1.4.0

func NewDeleteApiTeamsOriginOrIdRequest(server string, originOrId string) (*http.Request, error)

NewDeleteApiTeamsOriginOrIdRequest generates requests for DeleteApiTeamsOriginOrId

func NewDeleteApiViewsOriginOrIdRequest

func NewDeleteApiViewsOriginOrIdRequest(server string, originOrId string, params *DeleteApiViewsOriginOrIdParams) (*http.Request, error)

NewDeleteApiViewsOriginOrIdRequest generates requests for DeleteApiViewsOriginOrId

func NewGetApiAlertingCheckRulesOriginOrIdRequest

func NewGetApiAlertingCheckRulesOriginOrIdRequest(server string, originOrId string, params *GetApiAlertingCheckRulesOriginOrIdParams) (*http.Request, error)

NewGetApiAlertingCheckRulesOriginOrIdRequest generates requests for GetApiAlertingCheckRulesOriginOrId

func NewGetApiAlertingCheckRulesRequest

func NewGetApiAlertingCheckRulesRequest(server string, params *GetApiAlertingCheckRulesParams) (*http.Request, error)

NewGetApiAlertingCheckRulesRequest generates requests for GetApiAlertingCheckRules

func NewGetApiDashboardsOriginOrIdRequest

func NewGetApiDashboardsOriginOrIdRequest(server string, originOrId string, params *GetApiDashboardsOriginOrIdParams) (*http.Request, error)

NewGetApiDashboardsOriginOrIdRequest generates requests for GetApiDashboardsOriginOrId

func NewGetApiDashboardsRequest

func NewGetApiDashboardsRequest(server string, params *GetApiDashboardsParams) (*http.Request, error)

NewGetApiDashboardsRequest generates requests for GetApiDashboards

func NewGetApiMembersRequest added in v1.4.0

func NewGetApiMembersRequest(server string) (*http.Request, error)

NewGetApiMembersRequest generates requests for GetApiMembers

func NewGetApiRecordingRuleGroupsOriginOrIdRequest added in v1.6.0

func NewGetApiRecordingRuleGroupsOriginOrIdRequest(server string, originOrId string, params *GetApiRecordingRuleGroupsOriginOrIdParams) (*http.Request, error)

NewGetApiRecordingRuleGroupsOriginOrIdRequest generates requests for GetApiRecordingRuleGroupsOriginOrId

func NewGetApiRecordingRuleGroupsOriginOrIdVersionsVersionRequest added in v1.6.0

func NewGetApiRecordingRuleGroupsOriginOrIdVersionsVersionRequest(server string, originOrId string, version int64, params *GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams) (*http.Request, error)

NewGetApiRecordingRuleGroupsOriginOrIdVersionsVersionRequest generates requests for GetApiRecordingRuleGroupsOriginOrIdVersionsVersion

func NewGetApiRecordingRuleGroupsRequest added in v1.6.0

func NewGetApiRecordingRuleGroupsRequest(server string, params *GetApiRecordingRuleGroupsParams) (*http.Request, error)

NewGetApiRecordingRuleGroupsRequest generates requests for GetApiRecordingRuleGroups

func NewGetApiSamplingRulesOriginOrIdRequest added in v1.1.0

func NewGetApiSamplingRulesOriginOrIdRequest(server string, originOrId string, params *GetApiSamplingRulesOriginOrIdParams) (*http.Request, error)

NewGetApiSamplingRulesOriginOrIdRequest generates requests for GetApiSamplingRulesOriginOrId

func NewGetApiSamplingRulesRequest added in v1.1.0

func NewGetApiSamplingRulesRequest(server string, params *GetApiSamplingRulesParams) (*http.Request, error)

NewGetApiSamplingRulesRequest generates requests for GetApiSamplingRules

func NewGetApiSyntheticChecksLocationsRequest added in v1.6.0

func NewGetApiSyntheticChecksLocationsRequest(server string) (*http.Request, error)

NewGetApiSyntheticChecksLocationsRequest generates requests for GetApiSyntheticChecksLocations

func NewGetApiSyntheticChecksOriginOrIdRequest

func NewGetApiSyntheticChecksOriginOrIdRequest(server string, originOrId string, params *GetApiSyntheticChecksOriginOrIdParams) (*http.Request, error)

NewGetApiSyntheticChecksOriginOrIdRequest generates requests for GetApiSyntheticChecksOriginOrId

func NewGetApiSyntheticChecksRequest

func NewGetApiSyntheticChecksRequest(server string, params *GetApiSyntheticChecksParams) (*http.Request, error)

NewGetApiSyntheticChecksRequest generates requests for GetApiSyntheticChecks

func NewGetApiTeamsOriginOrIdRequest added in v1.4.0

func NewGetApiTeamsOriginOrIdRequest(server string, originOrId string) (*http.Request, error)

NewGetApiTeamsOriginOrIdRequest generates requests for GetApiTeamsOriginOrId

func NewGetApiTeamsRequest added in v1.4.0

func NewGetApiTeamsRequest(server string) (*http.Request, error)

NewGetApiTeamsRequest generates requests for GetApiTeams

func NewGetApiViewsOriginOrIdRequest

func NewGetApiViewsOriginOrIdRequest(server string, originOrId string, params *GetApiViewsOriginOrIdParams) (*http.Request, error)

NewGetApiViewsOriginOrIdRequest generates requests for GetApiViewsOriginOrId

func NewGetApiViewsRequest

func NewGetApiViewsRequest(server string, params *GetApiViewsParams) (*http.Request, error)

NewGetApiViewsRequest generates requests for GetApiViews

func NewGetOauthAuthorizeRequest added in v1.6.0

func NewGetOauthAuthorizeRequest(server string, params *GetOauthAuthorizeParams) (*http.Request, error)

NewGetOauthAuthorizeRequest generates requests for GetOauthAuthorize

func NewGetWellKnownOauthAuthorizationServerRequest added in v1.6.0

func NewGetWellKnownOauthAuthorizationServerRequest(server string) (*http.Request, error)

NewGetWellKnownOauthAuthorizationServerRequest generates requests for GetWellKnownOauthAuthorizationServer

func NewGetWellKnownOauthProtectedResourceRequest added in v1.6.0

func NewGetWellKnownOauthProtectedResourceRequest(server string) (*http.Request, error)

NewGetWellKnownOauthProtectedResourceRequest generates requests for GetWellKnownOauthProtectedResource

func NewPostApiAlertingCheckRulesRequest

func NewPostApiAlertingCheckRulesRequest(server string, params *PostApiAlertingCheckRulesParams, body PostApiAlertingCheckRulesJSONRequestBody) (*http.Request, error)

NewPostApiAlertingCheckRulesRequest calls the generic PostApiAlertingCheckRules builder with application/json body

func NewPostApiAlertingCheckRulesRequestWithBody

func NewPostApiAlertingCheckRulesRequestWithBody(server string, params *PostApiAlertingCheckRulesParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiAlertingCheckRulesRequestWithBody generates requests for PostApiAlertingCheckRules with any type of body

func NewPostApiDashboardsRequest

func NewPostApiDashboardsRequest(server string, params *PostApiDashboardsParams, body PostApiDashboardsJSONRequestBody) (*http.Request, error)

NewPostApiDashboardsRequest calls the generic PostApiDashboards builder with application/json body

func NewPostApiDashboardsRequestWithBody

func NewPostApiDashboardsRequestWithBody(server string, params *PostApiDashboardsParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiDashboardsRequestWithBody generates requests for PostApiDashboards with any type of body

func NewPostApiImportCheckRuleRequest

func NewPostApiImportCheckRuleRequest(server string, params *PostApiImportCheckRuleParams, body PostApiImportCheckRuleJSONRequestBody) (*http.Request, error)

NewPostApiImportCheckRuleRequest calls the generic PostApiImportCheckRule builder with application/json body

func NewPostApiImportCheckRuleRequestWithBody

func NewPostApiImportCheckRuleRequestWithBody(server string, params *PostApiImportCheckRuleParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiImportCheckRuleRequestWithBody generates requests for PostApiImportCheckRule with any type of body

func NewPostApiImportDashboardRequest

func NewPostApiImportDashboardRequest(server string, params *PostApiImportDashboardParams, body PostApiImportDashboardJSONRequestBody) (*http.Request, error)

NewPostApiImportDashboardRequest calls the generic PostApiImportDashboard builder with application/json body

func NewPostApiImportDashboardRequestWithBody

func NewPostApiImportDashboardRequestWithBody(server string, params *PostApiImportDashboardParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiImportDashboardRequestWithBody generates requests for PostApiImportDashboard with any type of body

func NewPostApiImportSyntheticCheckRequest

func NewPostApiImportSyntheticCheckRequest(server string, params *PostApiImportSyntheticCheckParams, body PostApiImportSyntheticCheckJSONRequestBody) (*http.Request, error)

NewPostApiImportSyntheticCheckRequest calls the generic PostApiImportSyntheticCheck builder with application/json body

func NewPostApiImportSyntheticCheckRequestWithBody

func NewPostApiImportSyntheticCheckRequestWithBody(server string, params *PostApiImportSyntheticCheckParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiImportSyntheticCheckRequestWithBody generates requests for PostApiImportSyntheticCheck with any type of body

func NewPostApiImportViewRequest

func NewPostApiImportViewRequest(server string, params *PostApiImportViewParams, body PostApiImportViewJSONRequestBody) (*http.Request, error)

NewPostApiImportViewRequest calls the generic PostApiImportView builder with application/json body

func NewPostApiImportViewRequestWithBody

func NewPostApiImportViewRequestWithBody(server string, params *PostApiImportViewParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiImportViewRequestWithBody generates requests for PostApiImportView with any type of body

func NewPostApiLogsRequest

func NewPostApiLogsRequest(server string, body PostApiLogsJSONRequestBody) (*http.Request, error)

NewPostApiLogsRequest calls the generic PostApiLogs builder with application/json body

func NewPostApiLogsRequestWithBody

func NewPostApiLogsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiLogsRequestWithBody generates requests for PostApiLogs with any type of body

func NewPostApiMembersRequest added in v1.4.0

func NewPostApiMembersRequest(server string, body PostApiMembersJSONRequestBody) (*http.Request, error)

NewPostApiMembersRequest calls the generic PostApiMembers builder with application/json body

func NewPostApiMembersRequestWithBody added in v1.4.0

func NewPostApiMembersRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiMembersRequestWithBody generates requests for PostApiMembers with any type of body

func NewPostApiRecordingRuleGroupsRequest added in v1.6.0

func NewPostApiRecordingRuleGroupsRequest(server string, body PostApiRecordingRuleGroupsJSONRequestBody) (*http.Request, error)

NewPostApiRecordingRuleGroupsRequest calls the generic PostApiRecordingRuleGroups builder with application/json body

func NewPostApiRecordingRuleGroupsRequestWithBody added in v1.6.0

func NewPostApiRecordingRuleGroupsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiRecordingRuleGroupsRequestWithBody generates requests for PostApiRecordingRuleGroups with any type of body

func NewPostApiSamplingRulesRequest added in v1.1.0

func NewPostApiSamplingRulesRequest(server string, params *PostApiSamplingRulesParams, body PostApiSamplingRulesJSONRequestBody) (*http.Request, error)

NewPostApiSamplingRulesRequest calls the generic PostApiSamplingRules builder with application/json body

func NewPostApiSamplingRulesRequestWithBody added in v1.1.0

func NewPostApiSamplingRulesRequestWithBody(server string, params *PostApiSamplingRulesParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiSamplingRulesRequestWithBody generates requests for PostApiSamplingRules with any type of body

func NewPostApiSpansRequest

func NewPostApiSpansRequest(server string, body PostApiSpansJSONRequestBody) (*http.Request, error)

NewPostApiSpansRequest calls the generic PostApiSpans builder with application/json body

func NewPostApiSpansRequestWithBody

func NewPostApiSpansRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiSpansRequestWithBody generates requests for PostApiSpans with any type of body

func NewPostApiSqlRequest added in v1.6.0

func NewPostApiSqlRequest(server string, body PostApiSqlJSONRequestBody) (*http.Request, error)

NewPostApiSqlRequest calls the generic PostApiSql builder with application/json body

func NewPostApiSqlRequestWithBody added in v1.6.0

func NewPostApiSqlRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiSqlRequestWithBody generates requests for PostApiSql with any type of body

func NewPostApiSyntheticChecksRequest

func NewPostApiSyntheticChecksRequest(server string, params *PostApiSyntheticChecksParams, body PostApiSyntheticChecksJSONRequestBody) (*http.Request, error)

NewPostApiSyntheticChecksRequest calls the generic PostApiSyntheticChecks builder with application/json body

func NewPostApiSyntheticChecksRequestWithBody

func NewPostApiSyntheticChecksRequestWithBody(server string, params *PostApiSyntheticChecksParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiSyntheticChecksRequestWithBody generates requests for PostApiSyntheticChecks with any type of body

func NewPostApiSyntheticChecksTestRequest added in v1.4.0

func NewPostApiSyntheticChecksTestRequest(server string, body PostApiSyntheticChecksTestJSONRequestBody) (*http.Request, error)

NewPostApiSyntheticChecksTestRequest calls the generic PostApiSyntheticChecksTest builder with application/json body

func NewPostApiSyntheticChecksTestRequestWithBody added in v1.4.0

func NewPostApiSyntheticChecksTestRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiSyntheticChecksTestRequestWithBody generates requests for PostApiSyntheticChecksTest with any type of body

func NewPostApiTeamsOriginOrIdMembersRequest added in v1.4.0

func NewPostApiTeamsOriginOrIdMembersRequest(server string, originOrId string, body PostApiTeamsOriginOrIdMembersJSONRequestBody) (*http.Request, error)

NewPostApiTeamsOriginOrIdMembersRequest calls the generic PostApiTeamsOriginOrIdMembers builder with application/json body

func NewPostApiTeamsOriginOrIdMembersRequestWithBody added in v1.4.0

func NewPostApiTeamsOriginOrIdMembersRequestWithBody(server string, originOrId string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiTeamsOriginOrIdMembersRequestWithBody generates requests for PostApiTeamsOriginOrIdMembers with any type of body

func NewPostApiTeamsRequest added in v1.4.0

func NewPostApiTeamsRequest(server string, body PostApiTeamsJSONRequestBody) (*http.Request, error)

NewPostApiTeamsRequest calls the generic PostApiTeams builder with application/json body

func NewPostApiTeamsRequestWithBody added in v1.4.0

func NewPostApiTeamsRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostApiTeamsRequestWithBody generates requests for PostApiTeams with any type of body

func NewPostApiViewsRequest

func NewPostApiViewsRequest(server string, params *PostApiViewsParams, body PostApiViewsJSONRequestBody) (*http.Request, error)

NewPostApiViewsRequest calls the generic PostApiViews builder with application/json body

func NewPostApiViewsRequestWithBody

func NewPostApiViewsRequestWithBody(server string, params *PostApiViewsParams, contentType string, body io.Reader) (*http.Request, error)

NewPostApiViewsRequestWithBody generates requests for PostApiViews with any type of body

func NewPostOauthRegisterRequest added in v1.6.0

func NewPostOauthRegisterRequest(server string, body PostOauthRegisterJSONRequestBody) (*http.Request, error)

NewPostOauthRegisterRequest calls the generic PostOauthRegister builder with application/json body

func NewPostOauthRegisterRequestWithBody added in v1.6.0

func NewPostOauthRegisterRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostOauthRegisterRequestWithBody generates requests for PostOauthRegister with any type of body

func NewPostOauthRevokeRequestWithBody added in v1.6.0

func NewPostOauthRevokeRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostOauthRevokeRequestWithBody generates requests for PostOauthRevoke with any type of body

func NewPostOauthRevokeRequestWithFormdataBody added in v1.6.0

func NewPostOauthRevokeRequestWithFormdataBody(server string, body PostOauthRevokeFormdataRequestBody) (*http.Request, error)

NewPostOauthRevokeRequestWithFormdataBody calls the generic PostOauthRevoke builder with application/x-www-form-urlencoded body

func NewPostOauthTokenRequestWithBody added in v1.6.0

func NewPostOauthTokenRequestWithBody(server string, contentType string, body io.Reader) (*http.Request, error)

NewPostOauthTokenRequestWithBody generates requests for PostOauthToken with any type of body

func NewPostOauthTokenRequestWithFormdataBody added in v1.6.0

func NewPostOauthTokenRequestWithFormdataBody(server string, body PostOauthTokenFormdataRequestBody) (*http.Request, error)

NewPostOauthTokenRequestWithFormdataBody calls the generic PostOauthToken builder with application/x-www-form-urlencoded body

func NewPutApiAlertingCheckRulesOriginOrIdRequest

func NewPutApiAlertingCheckRulesOriginOrIdRequest(server string, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, body PutApiAlertingCheckRulesOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiAlertingCheckRulesOriginOrIdRequest calls the generic PutApiAlertingCheckRulesOriginOrId builder with application/json body

func NewPutApiAlertingCheckRulesOriginOrIdRequestWithBody

func NewPutApiAlertingCheckRulesOriginOrIdRequestWithBody(server string, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, contentType string, body io.Reader) (*http.Request, error)

NewPutApiAlertingCheckRulesOriginOrIdRequestWithBody generates requests for PutApiAlertingCheckRulesOriginOrId with any type of body

func NewPutApiDashboardsOriginOrIdRequest

func NewPutApiDashboardsOriginOrIdRequest(server string, originOrId string, params *PutApiDashboardsOriginOrIdParams, body PutApiDashboardsOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiDashboardsOriginOrIdRequest calls the generic PutApiDashboardsOriginOrId builder with application/json body

func NewPutApiDashboardsOriginOrIdRequestWithBody

func NewPutApiDashboardsOriginOrIdRequestWithBody(server string, originOrId string, params *PutApiDashboardsOriginOrIdParams, contentType string, body io.Reader) (*http.Request, error)

NewPutApiDashboardsOriginOrIdRequestWithBody generates requests for PutApiDashboardsOriginOrId with any type of body

func NewPutApiRecordingRuleGroupsOriginOrIdRequest added in v1.6.0

func NewPutApiRecordingRuleGroupsOriginOrIdRequest(server string, originOrId string, body PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiRecordingRuleGroupsOriginOrIdRequest calls the generic PutApiRecordingRuleGroupsOriginOrId builder with application/json body

func NewPutApiRecordingRuleGroupsOriginOrIdRequestWithBody added in v1.6.0

func NewPutApiRecordingRuleGroupsOriginOrIdRequestWithBody(server string, originOrId string, contentType string, body io.Reader) (*http.Request, error)

NewPutApiRecordingRuleGroupsOriginOrIdRequestWithBody generates requests for PutApiRecordingRuleGroupsOriginOrId with any type of body

func NewPutApiSamplingRulesOriginOrIdRequest added in v1.1.0

func NewPutApiSamplingRulesOriginOrIdRequest(server string, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, body PutApiSamplingRulesOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiSamplingRulesOriginOrIdRequest calls the generic PutApiSamplingRulesOriginOrId builder with application/json body

func NewPutApiSamplingRulesOriginOrIdRequestWithBody added in v1.1.0

func NewPutApiSamplingRulesOriginOrIdRequestWithBody(server string, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, contentType string, body io.Reader) (*http.Request, error)

NewPutApiSamplingRulesOriginOrIdRequestWithBody generates requests for PutApiSamplingRulesOriginOrId with any type of body

func NewPutApiSyntheticChecksOriginOrIdRequest

func NewPutApiSyntheticChecksOriginOrIdRequest(server string, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, body PutApiSyntheticChecksOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiSyntheticChecksOriginOrIdRequest calls the generic PutApiSyntheticChecksOriginOrId builder with application/json body

func NewPutApiSyntheticChecksOriginOrIdRequestWithBody

func NewPutApiSyntheticChecksOriginOrIdRequestWithBody(server string, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, contentType string, body io.Reader) (*http.Request, error)

NewPutApiSyntheticChecksOriginOrIdRequestWithBody generates requests for PutApiSyntheticChecksOriginOrId with any type of body

func NewPutApiTeamsOriginOrIdDisplayRequest added in v1.4.0

func NewPutApiTeamsOriginOrIdDisplayRequest(server string, originOrId string, body PutApiTeamsOriginOrIdDisplayJSONRequestBody) (*http.Request, error)

NewPutApiTeamsOriginOrIdDisplayRequest calls the generic PutApiTeamsOriginOrIdDisplay builder with application/json body

func NewPutApiTeamsOriginOrIdDisplayRequestWithBody added in v1.4.0

func NewPutApiTeamsOriginOrIdDisplayRequestWithBody(server string, originOrId string, contentType string, body io.Reader) (*http.Request, error)

NewPutApiTeamsOriginOrIdDisplayRequestWithBody generates requests for PutApiTeamsOriginOrIdDisplay with any type of body

func NewPutApiViewsOriginOrIdRequest

func NewPutApiViewsOriginOrIdRequest(server string, originOrId string, params *PutApiViewsOriginOrIdParams, body PutApiViewsOriginOrIdJSONRequestBody) (*http.Request, error)

NewPutApiViewsOriginOrIdRequest calls the generic PutApiViewsOriginOrId builder with application/json body

func NewPutApiViewsOriginOrIdRequestWithBody

func NewPutApiViewsOriginOrIdRequestWithBody(server string, originOrId string, params *PutApiViewsOriginOrIdParams, contentType string, body io.Reader) (*http.Request, error)

NewPutApiViewsOriginOrIdRequestWithBody generates requests for PutApiViewsOriginOrId with any type of body

func Ptr

func Ptr[T any](v T) *T

Ptr returns a pointer to the given value. This is useful for creating pointers to literals when calling API methods that accept optional parameters.

Example:

client.ListDashboards(ctx, dash0.Ptr("default"))

func SetCheckRuleDataset added in v1.6.0

func SetCheckRuleDataset(rule *PrometheusAlertRule, dataset string)

SetCheckRuleDataset sets the dataset on a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Name: "HighErrorRate"}
	dash0.SetCheckRuleDataset(rule, "production")
	fmt.Println(dash0.StringValue(rule.Dataset))
}
Output:
production

func SetCheckRuleID added in v1.6.0

func SetCheckRuleID(rule *PrometheusAlertRule, id string)

SetCheckRuleID sets the ID on a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Name: "HighErrorRate"}
	dash0.SetCheckRuleID(rule, "cr-42")
	fmt.Println(*rule.Id)
}
Output:
cr-42

func SetCheckRuleIDIfAbsent added in v1.6.0

func SetCheckRuleIDIfAbsent(rule *PrometheusAlertRule, id string)

SetCheckRuleIDIfAbsent sets the ID on a check rule definition only if it is not already set.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{Id: dash0.Ptr("existing")}
	dash0.SetCheckRuleIDIfAbsent(rule, "new-id")
	fmt.Println(*rule.Id)
}
Output:
existing

func SetDashboardDataset added in v1.6.0

func SetDashboardDataset(dashboard *DashboardDefinition, dataset string)

SetDashboardDataset sets the dataset on a dashboard definition, initializing the dash0Extensions struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{}
	dash0.SetDashboardDataset(dashboard, "production")
	fmt.Println(string(*dashboard.Metadata.Dash0Extensions.Dataset))
}
Output:
production

func SetDashboardFolderPath added in v1.6.0

func SetDashboardFolderPath(dashboard *DashboardDefinition, folderPath string)

SetDashboardFolderPath sets the folder path on a dashboard definition, initializing the annotations struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{}
	dash0.SetDashboardFolderPath(dashboard, "/team/sre")
	fmt.Println(*dashboard.Metadata.Annotations.Dash0ComfolderPath)
}
Output:
/team/sre

func SetDashboardID added in v1.6.0

func SetDashboardID(dashboard *DashboardDefinition, id string)

SetDashboardID sets the ID on a dashboard definition, initializing the dash0Extensions struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{}
	dash0.SetDashboardID(dashboard, "d-456")
	fmt.Println(*dashboard.Metadata.Dash0Extensions.Id)
}
Output:
d-456

func SetDashboardIDIfAbsent added in v1.6.0

func SetDashboardIDIfAbsent(dashboard *DashboardDefinition, id string)

SetDashboardIDIfAbsent sets the ID on a dashboard definition only if it is not already set, initializing the dash0Extensions struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Dash0Extensions: &dash0.DashboardMetadataExtensions{
				Id: dash0.Ptr("existing"),
			},
		},
	}
	// Does not overwrite an existing ID.
	dash0.SetDashboardIDIfAbsent(dashboard, "new-id")
	fmt.Println(*dashboard.Metadata.Dash0Extensions.Id)
}
Output:
existing

func SetPersesDashboardDataset added in v1.6.0

func SetPersesDashboardDataset(perses *PersesDashboard, dataset string)

SetPersesDashboardDataset sets the dash0.com/dataset label on a PersesDashboard CRD, initializing the labels map if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	perses := &dash0.PersesDashboard{}
	dash0.SetPersesDashboardDataset(perses, "production")
	fmt.Println(perses.Metadata.Labels["dash0.com/dataset"])
}
Output:
production

func SetPersesDashboardFolderPath added in v1.6.0

func SetPersesDashboardFolderPath(perses *PersesDashboard, folderPath string)

SetPersesDashboardFolderPath sets the dash0.com/folder-path annotation on a PersesDashboard CRD, initializing the annotations map if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	perses := &dash0.PersesDashboard{}
	dash0.SetPersesDashboardFolderPath(perses, "/team/sre")
	fmt.Println(perses.Metadata.Annotations[dash0.AnnotationFolderPath])
}
Output:
/team/sre

func SetPersesDashboardID added in v1.6.0

func SetPersesDashboardID(perses *PersesDashboard, id string)

SetPersesDashboardID sets the dash0.com/id label on a PersesDashboard CRD, initializing the labels map if needed.

func SetPersesDashboardIDIfAbsent added in v1.6.0

func SetPersesDashboardIDIfAbsent(perses *PersesDashboard, id string)

SetPersesDashboardIDIfAbsent sets the dash0.com/id label on a PersesDashboard CRD only if it is not already set, initializing the labels map if needed.

func SetPrometheusRuleDataset added in v1.6.0

func SetPrometheusRuleDataset(rule *PrometheusRules, dataset string)

SetPrometheusRuleDataset sets the dash0.com/dataset label on a PrometheusRules CRD, initializing the labels map if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusRules{}
	dash0.SetPrometheusRuleDataset(rule, "production")
	fmt.Println(rule.Metadata.Labels["dash0.com/dataset"])
}
Output:
production

func SetPrometheusRuleID added in v1.6.0

func SetPrometheusRuleID(rule *PrometheusRules, id string)

SetPrometheusRuleID sets the dash0.com/id label on a PrometheusRules CRD, initializing the labels map if needed.

func SetPrometheusRuleIDIfAbsent added in v1.6.0

func SetPrometheusRuleIDIfAbsent(rule *PrometheusRules, id string)

SetPrometheusRuleIDIfAbsent sets the dash0.com/id label on a PrometheusRules CRD only if it is not already set, initializing the labels map if needed.

func SetSyntheticCheckDataset added in v1.6.0

func SetSyntheticCheckDataset(check *SyntheticCheckDefinition, dataset string)

SetSyntheticCheckDataset sets the dataset on a synthetic check definition, initializing the labels struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	check := &dash0.SyntheticCheckDefinition{}
	dash0.SetSyntheticCheckDataset(check, "production")
	fmt.Println(*check.Metadata.Labels.Dash0Comdataset)
}
Output:
production

func SetSyntheticCheckID added in v1.6.0

func SetSyntheticCheckID(check *SyntheticCheckDefinition, id string)

SetSyntheticCheckID sets the dash0.com/id label on a synthetic check definition, initializing the labels struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	check := &dash0.SyntheticCheckDefinition{}
	dash0.SetSyntheticCheckID(check, "sc-7")
	fmt.Println(*check.Metadata.Labels.Dash0Comid)
}
Output:
sc-7

func SetSyntheticCheckIDIfAbsent added in v1.6.0

func SetSyntheticCheckIDIfAbsent(check *SyntheticCheckDefinition, id string)

SetSyntheticCheckIDIfAbsent sets the dash0.com/id label on a synthetic check definition only if it is not already set, initializing the labels struct if needed.

func SetViewDataset added in v1.6.0

func SetViewDataset(view *ViewDefinition, dataset string)

SetViewDataset sets the dataset on a view definition, initializing the labels struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	view := &dash0.ViewDefinition{}
	dash0.SetViewDataset(view, "production")
	fmt.Println(*view.Metadata.Labels.Dash0Comdataset)
}
Output:
production

func SetViewID added in v1.6.0

func SetViewID(view *ViewDefinition, id string)

SetViewID sets the dash0.com/id label on a view definition, initializing the labels struct if needed.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	view := &dash0.ViewDefinition{}
	dash0.SetViewID(view, "v-99")
	fmt.Println(*view.Metadata.Labels.Dash0Comid)
}
Output:
v-99

func SetViewIDIfAbsent added in v1.6.0

func SetViewIDIfAbsent(view *ViewDefinition, id string)

SetViewIDIfAbsent sets the dash0.com/id label on a view definition only if it is not already set, initializing the labels struct if needed.

func String

func String(v string) *string

String returns a pointer to the given string value. This is a convenience wrapper around Ptr for the common case of string pointers.

Example:

client.ListDashboards(ctx, dash0.String("default"))

func StringValue

func StringValue(p *string) string

StringValue returns the value of a string pointer, or empty string if nil.

func StripCheckRuleServerFields added in v1.6.0

func StripCheckRuleServerFields(rule *PrometheusAlertRule)

StripCheckRuleServerFields removes server-generated fields from a check rule definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	rule := &dash0.PrometheusAlertRule{
		Name:    "HighErrorRate",
		Dataset: dash0.Ptr("prod"),
	}
	dash0.StripCheckRuleServerFields(rule)
	fmt.Println(rule.Dataset == nil)
}
Output:
true

func StripDashboardServerFields added in v1.6.0

func StripDashboardServerFields(dashboard *DashboardDefinition)

StripDashboardServerFields removes server-generated metadata fields from a dashboard definition.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	dashboard := &dash0.DashboardDefinition{
		Metadata: dash0.DashboardMetadata{
			Version: dash0.Ptr(int64(3)),
		},
	}
	dash0.StripDashboardServerFields(dashboard)
	fmt.Println(dashboard.Metadata.Version == nil)
}
Output:
true

func StripSyntheticCheckServerFields added in v1.6.0

func StripSyntheticCheckServerFields(check *SyntheticCheckDefinition)

StripSyntheticCheckServerFields removes server-generated fields from a synthetic check definition.

func StripViewServerFields added in v1.6.0

func StripViewServerFields(view *ViewDefinition)

StripViewServerFields removes server-generated fields from a view definition.

func WithRequestEditorFn

func WithRequestEditorFn(fn RequestEditorFn) generatedClientOption

WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.

Types

type APIError

type APIError struct {
	// StatusCode is the HTTP status code.
	StatusCode int

	// Status is the HTTP status text.
	Status string

	// Body is the raw response body.
	Body string

	// Message is the error message extracted from the response.
	Message string

	// TraceID is the trace ID from the x-trace-id header if available.
	TraceID string
}

APIError represents an error response from the Dash0 API.

func NewAPIError

func NewAPIError(resp *http.Response) *APIError

NewAPIError creates an APIError from an HTTP response. Note: This function tries to read the response body. If the body has already been read (e.g., by oapi-codegen), use newAPIErrorWithBody instead.

func (*APIError) Error

func (e *APIError) Error() string

Error implements the error interface.

type AccessibleAsset added in v1.4.0

type AccessibleAsset struct {
	// CreatedAt A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	CreatedAt FixedTime         `json:"createdAt"`
	Creator   *MemberDefinition `json:"creator,omitempty"`

	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset Dataset `json:"dataset"`

	// HasAccess returns the information if the logged-in user has access to this asset
	HasAccess        bool     `json:"hasAccess"`
	Id               string   `json:"id"`
	Name             string   `json:"name"`
	PermittedActions []Action `json:"permittedActions"`

	// Type returns for views the information which type of view it is
	Type *string `json:"type,omitempty"`
}

AccessibleAsset defines model for AccessibleAsset.

type Action added in v1.4.0

type Action = string

Action Not defined as an enum, because we will eventually support wildcards like `ingest:*`.

type AddTeamMembersRequest added in v1.4.0

type AddTeamMembersRequest struct {
	// MemberIds Add an existing organization member to this team.
	MemberIds []string `json:"memberIds"`
}

AddTeamMembersRequest defines model for AddTeamMembersRequest.

type AnyValue

type AnyValue struct {
	BoolValue   *bool    `json:"boolValue,omitempty"`
	BytesValue  *[]byte  `json:"bytesValue,omitempty"`
	DoubleValue *float64 `json:"doubleValue,omitempty"`
	IntValue    *string  `json:"intValue,omitempty"`
	StringValue *string  `json:"stringValue,omitempty"`
}

AnyValue AnyValue is used to represent any type of attribute value. AnyValue may contain a primitive value such as a string or integer or it may contain an arbitrary nested object containing arrays, key-value lists and primitives.

type AttributeFilter

type AttributeFilter struct {
	// Key The attribute key to be filtered.
	Key AttributeFilterKey `json:"key"`

	// Operator The match operation for filtering attributes.
	//
	// #### Equality Operators
	// - `is` - equals (attribute exists and has a matching value)
	// - `is_not` - not equals (attribute exists and has a different value)
	//
	// #### Existence Operators
	// - `is_set` - is set (attribute exists)
	// - `is_not_set` - is not set (attribute does not exist)
	//
	// #### Multiple Value Operators
	// - `is_one_of` - is any of (attribute exists and has a value that is in the specified values)
	// - `is_not_one_of` - is not any of (attribute exists and has a value that is not in the specified values)
	//
	// #### Comparison Operators
	// - `gt` - greater than
	// - `lt` - less than
	// - `gte` - greater than or equal
	// - `lte` - less than or equal
	//
	// #### Pattern Matching Operators
	// - `matches` - match regex expression (attribute exists and matches the regular expression)
	// - `does_not_match` - does not match regex expression (attribute exists and does not match the regular expression)
	//
	// #### String Operators
	// - `contains` - contains (attribute exists and contains the specified value)
	// - `does_not_contain` - does not contain (attribute exists and does not contain the specified value)
	// - `starts_with` - starts with (attribute exists and starts with the specified value)
	// - `does_not_start_with` - does not start with (attribute exists and does not start with the specified value)
	// - `ends_with` - ends with (attribute exists and ends with the specified value)
	// - `does_not_end_with` - does not end with (attribute exists and does not end with the specified value)
	//
	// #### Special Operators
	// - `is_any` - matches any value, ignoring whether the key exists or not
	Operator AttributeFilterOperator `json:"operator"`
	Value    *AttributeFilter_Value  `json:"value,omitempty"`

	// Values List of values to match against. This parameter is mandatory for the is_one_of and is_not_one_of operators.
	Values *[]AttributeFilter_Values_Item `json:"values,omitempty"`
}

AttributeFilter defines model for AttributeFilter.

type AttributeFilterAnyValue

type AttributeFilterAnyValue = AnyValue

AttributeFilterAnyValue AnyValue is used to represent any type of attribute value. AnyValue may contain a primitive value such as a string or integer or it may contain an arbitrary nested object containing arrays, key-value lists and primitives.

type AttributeFilterKey

type AttributeFilterKey = string

AttributeFilterKey The attribute key to be filtered.

type AttributeFilterOperator

type AttributeFilterOperator string

AttributeFilterOperator The match operation for filtering attributes.

#### Equality Operators - `is` - equals (attribute exists and has a matching value) - `is_not` - not equals (attribute exists and has a different value)

#### Existence Operators - `is_set` - is set (attribute exists) - `is_not_set` - is not set (attribute does not exist)

#### Multiple Value Operators - `is_one_of` - is any of (attribute exists and has a value that is in the specified values) - `is_not_one_of` - is not any of (attribute exists and has a value that is not in the specified values)

#### Comparison Operators - `gt` - greater than - `lt` - less than - `gte` - greater than or equal - `lte` - less than or equal

#### Pattern Matching Operators - `matches` - match regex expression (attribute exists and matches the regular expression) - `does_not_match` - does not match regex expression (attribute exists and does not match the regular expression)

#### String Operators - `contains` - contains (attribute exists and contains the specified value) - `does_not_contain` - does not contain (attribute exists and does not contain the specified value) - `starts_with` - starts with (attribute exists and starts with the specified value) - `does_not_start_with` - does not start with (attribute exists and does not start with the specified value) - `ends_with` - ends with (attribute exists and ends with the specified value) - `does_not_end_with` - does not end with (attribute exists and does not end with the specified value)

#### Special Operators - `is_any` - matches any value, ignoring whether the key exists or not

const (
	AttributeFilterOperatorContains         AttributeFilterOperator = "contains"
	AttributeFilterOperatorDoesNotContain   AttributeFilterOperator = "does_not_contain"
	AttributeFilterOperatorDoesNotEndWith   AttributeFilterOperator = "does_not_end_with"
	AttributeFilterOperatorDoesNotMatch     AttributeFilterOperator = "does_not_match"
	AttributeFilterOperatorDoesNotStartWith AttributeFilterOperator = "does_not_start_with"
	AttributeFilterOperatorEndsWith         AttributeFilterOperator = "ends_with"
	AttributeFilterOperatorGt               AttributeFilterOperator = "gt"
	AttributeFilterOperatorGte              AttributeFilterOperator = "gte"
	AttributeFilterOperatorIs               AttributeFilterOperator = "is"
	AttributeFilterOperatorIsAny            AttributeFilterOperator = "is_any"
	AttributeFilterOperatorIsNot            AttributeFilterOperator = "is_not"
	AttributeFilterOperatorIsNotOneOf       AttributeFilterOperator = "is_not_one_of"
	AttributeFilterOperatorIsNotSet         AttributeFilterOperator = "is_not_set"
	AttributeFilterOperatorIsOneOf          AttributeFilterOperator = "is_one_of"
	AttributeFilterOperatorIsSet            AttributeFilterOperator = "is_set"
	AttributeFilterOperatorLt               AttributeFilterOperator = "lt"
	AttributeFilterOperatorLte              AttributeFilterOperator = "lte"
	AttributeFilterOperatorMatches          AttributeFilterOperator = "matches"
	AttributeFilterOperatorStartsWith       AttributeFilterOperator = "starts_with"
)

Defines values for AttributeFilterOperator.

type AttributeFilterStringValue

type AttributeFilterStringValue = string

AttributeFilterStringValue AttributeFilterStringValue may contain a primitive value such as a regex pattern or string.

type AttributeFilter_Value

type AttributeFilter_Value struct {
	// contains filtered or unexported fields
}

AttributeFilter_Value defines model for AttributeFilter.Value.

func (AttributeFilter_Value) AsAttributeFilterAnyValue

func (t AttributeFilter_Value) AsAttributeFilterAnyValue() (AttributeFilterAnyValue, error)

AsAttributeFilterAnyValue returns the union data inside the AttributeFilter_Value as a AttributeFilterAnyValue

func (AttributeFilter_Value) AsAttributeFilterStringValue

func (t AttributeFilter_Value) AsAttributeFilterStringValue() (AttributeFilterStringValue, error)

AsAttributeFilterStringValue returns the union data inside the AttributeFilter_Value as a AttributeFilterStringValue

func (*AttributeFilter_Value) FromAttributeFilterAnyValue

func (t *AttributeFilter_Value) FromAttributeFilterAnyValue(v AttributeFilterAnyValue) error

FromAttributeFilterAnyValue overwrites any union data inside the AttributeFilter_Value as the provided AttributeFilterAnyValue

func (*AttributeFilter_Value) FromAttributeFilterStringValue

func (t *AttributeFilter_Value) FromAttributeFilterStringValue(v AttributeFilterStringValue) error

FromAttributeFilterStringValue overwrites any union data inside the AttributeFilter_Value as the provided AttributeFilterStringValue

func (AttributeFilter_Value) MarshalJSON

func (t AttributeFilter_Value) MarshalJSON() ([]byte, error)

func (*AttributeFilter_Value) MergeAttributeFilterAnyValue

func (t *AttributeFilter_Value) MergeAttributeFilterAnyValue(v AttributeFilterAnyValue) error

MergeAttributeFilterAnyValue performs a merge with any union data inside the AttributeFilter_Value, using the provided AttributeFilterAnyValue

func (*AttributeFilter_Value) MergeAttributeFilterStringValue

func (t *AttributeFilter_Value) MergeAttributeFilterStringValue(v AttributeFilterStringValue) error

MergeAttributeFilterStringValue performs a merge with any union data inside the AttributeFilter_Value, using the provided AttributeFilterStringValue

func (*AttributeFilter_Value) UnmarshalJSON

func (t *AttributeFilter_Value) UnmarshalJSON(b []byte) error

type AttributeFilter_Values_Item

type AttributeFilter_Values_Item struct {
	// contains filtered or unexported fields
}

AttributeFilter_Values_Item defines model for AttributeFilter.values.Item.

func (AttributeFilter_Values_Item) AsAttributeFilterAnyValue

func (t AttributeFilter_Values_Item) AsAttributeFilterAnyValue() (AttributeFilterAnyValue, error)

AsAttributeFilterAnyValue returns the union data inside the AttributeFilter_Values_Item as a AttributeFilterAnyValue

func (AttributeFilter_Values_Item) AsAttributeFilterStringValue

func (t AttributeFilter_Values_Item) AsAttributeFilterStringValue() (AttributeFilterStringValue, error)

AsAttributeFilterStringValue returns the union data inside the AttributeFilter_Values_Item as a AttributeFilterStringValue

func (*AttributeFilter_Values_Item) FromAttributeFilterAnyValue

func (t *AttributeFilter_Values_Item) FromAttributeFilterAnyValue(v AttributeFilterAnyValue) error

FromAttributeFilterAnyValue overwrites any union data inside the AttributeFilter_Values_Item as the provided AttributeFilterAnyValue

func (*AttributeFilter_Values_Item) FromAttributeFilterStringValue

func (t *AttributeFilter_Values_Item) FromAttributeFilterStringValue(v AttributeFilterStringValue) error

FromAttributeFilterStringValue overwrites any union data inside the AttributeFilter_Values_Item as the provided AttributeFilterStringValue

func (AttributeFilter_Values_Item) MarshalJSON

func (t AttributeFilter_Values_Item) MarshalJSON() ([]byte, error)

func (*AttributeFilter_Values_Item) MergeAttributeFilterAnyValue

func (t *AttributeFilter_Values_Item) MergeAttributeFilterAnyValue(v AttributeFilterAnyValue) error

MergeAttributeFilterAnyValue performs a merge with any union data inside the AttributeFilter_Values_Item, using the provided AttributeFilterAnyValue

func (*AttributeFilter_Values_Item) MergeAttributeFilterStringValue

func (t *AttributeFilter_Values_Item) MergeAttributeFilterStringValue(v AttributeFilterStringValue) error

MergeAttributeFilterStringValue performs a merge with any union data inside the AttributeFilter_Values_Item, using the provided AttributeFilterStringValue

func (*AttributeFilter_Values_Item) UnmarshalJSON

func (t *AttributeFilter_Values_Item) UnmarshalJSON(b []byte) error

type AxisScale

type AxisScale string

AxisScale defines model for AxisScale.

const (
	AxisScaleLinear AxisScale = "linear"
	AxisScaleLog10  AxisScale = "log10"
)

Defines values for AxisScale.

type CheckThresholds

type CheckThresholds struct {
	// Degraded The threshold value that defines when the check is in a degraded state. The value will be
	// interpolated into the expression field as `$__threshold`.
	Degraded *float64 `json:"degraded,omitempty"`

	// Failed The threshold value that defines when the check is in a failed state. The value will be
	// interpolated into the expression field as `$__threshold`.
	Failed *float64 `json:"failed,omitempty"`
}

CheckThresholds Thresholds to use for the `$__threshold` variable in the expression field.

type Client

type Client interface {
	// Dashboards
	ListDashboards(ctx context.Context, dataset *string) ([]*DashboardApiListItem, error)
	GetDashboard(ctx context.Context, originOrID string, dataset *string) (*DashboardDefinition, error)
	CreateDashboard(ctx context.Context, dashboard *DashboardDefinition, dataset *string) (*DashboardDefinition, error)
	UpdateDashboard(ctx context.Context, originOrID string, dashboard *DashboardDefinition, dataset *string) (*DashboardDefinition, error)
	DeleteDashboard(ctx context.Context, originOrID string, dataset *string) error
	ListDashboardsIter(ctx context.Context, dataset *string) *Iter[DashboardApiListItem]

	// Check Rules
	ListCheckRules(ctx context.Context, dataset *string) ([]*PrometheusAlertRuleApiListItem, error)
	GetCheckRule(ctx context.Context, originOrID string, dataset *string) (*PrometheusAlertRule, error)
	CreateCheckRule(ctx context.Context, rule *PrometheusAlertRule, dataset *string) (*PrometheusAlertRule, error)
	UpdateCheckRule(ctx context.Context, originOrID string, rule *PrometheusAlertRule, dataset *string) (*PrometheusAlertRule, error)
	DeleteCheckRule(ctx context.Context, originOrID string, dataset *string) error
	ListCheckRulesIter(ctx context.Context, dataset *string) *Iter[PrometheusAlertRuleApiListItem]

	// Synthetic Checks
	ListSyntheticChecks(ctx context.Context, dataset *string) ([]*SyntheticChecksApiListItem, error)
	GetSyntheticCheck(ctx context.Context, originOrID string, dataset *string) (*SyntheticCheckDefinition, error)
	CreateSyntheticCheck(ctx context.Context, check *SyntheticCheckDefinition, dataset *string) (*SyntheticCheckDefinition, error)
	UpdateSyntheticCheck(ctx context.Context, originOrID string, check *SyntheticCheckDefinition, dataset *string) (*SyntheticCheckDefinition, error)
	DeleteSyntheticCheck(ctx context.Context, originOrID string, dataset *string) error
	ListSyntheticChecksIter(ctx context.Context, dataset *string) *Iter[SyntheticChecksApiListItem]

	// Views
	ListViews(ctx context.Context, dataset *string) ([]*ViewApiListItem, error)
	GetView(ctx context.Context, originOrID string, dataset *string) (*ViewDefinition, error)
	CreateView(ctx context.Context, view *ViewDefinition, dataset *string) (*ViewDefinition, error)
	UpdateView(ctx context.Context, originOrID string, view *ViewDefinition, dataset *string) (*ViewDefinition, error)
	DeleteView(ctx context.Context, originOrID string, dataset *string) error
	ListViewsIter(ctx context.Context, dataset *string) *Iter[ViewApiListItem]

	// Sampling Rules
	ListSamplingRules(ctx context.Context, dataset *string) ([]*SamplingDefinition, error)
	GetSamplingRule(ctx context.Context, originOrID string, dataset *string) (*SamplingDefinition, error)
	CreateSamplingRule(ctx context.Context, rule *SamplingDefinition, dataset *string) (*SamplingDefinition, error)
	UpdateSamplingRule(ctx context.Context, originOrID string, rule *SamplingDefinition, dataset *string) (*SamplingDefinition, error)
	DeleteSamplingRule(ctx context.Context, originOrID string, dataset *string) error
	ListSamplingRulesIter(ctx context.Context, dataset *string) *Iter[SamplingDefinition]

	// Recording Rule Groups
	ListRecordingRuleGroups(ctx context.Context, dataset *string) ([]*RecordingRuleGroupDefinition, error)
	GetRecordingRuleGroup(ctx context.Context, originOrID string, dataset *string) (*RecordingRuleGroupDefinition, error)
	CreateRecordingRuleGroup(ctx context.Context, group *RecordingRuleGroupDefinition) (*RecordingRuleGroupDefinition, error)
	UpdateRecordingRuleGroup(ctx context.Context, originOrID string, group *RecordingRuleGroupDefinition) (*RecordingRuleGroupDefinition, error)
	DeleteRecordingRuleGroup(ctx context.Context, originOrID string, dataset *string) error
	ListRecordingRuleGroupsIter(ctx context.Context, dataset *string) *Iter[RecordingRuleGroupDefinition]

	// Members
	ListMembers(ctx context.Context) ([]*MemberDefinition, error)
	InviteMember(ctx context.Context, request *InviteMemberRequest) error
	DeleteMember(ctx context.Context, memberID string) error
	ListMembersIter(ctx context.Context) *Iter[MemberDefinition]

	// Teams
	ListTeams(ctx context.Context) ([]*TeamsListItem, error)
	CreateTeam(ctx context.Context, team *TeamDefinition) (*TeamDefinition, error)
	GetTeam(ctx context.Context, originOrID string) (*GetTeamResponse, error)
	DeleteTeam(ctx context.Context, originOrID string) error
	UpdateTeamDisplay(ctx context.Context, originOrID string, display *TeamDisplay) error
	AddTeamMembers(ctx context.Context, originOrID string, request *AddTeamMembersRequest) error
	RemoveTeamMember(ctx context.Context, originOrID string, memberID string) error
	ListTeamsIter(ctx context.Context) *Iter[TeamsListItem]

	// Spans
	GetSpans(ctx context.Context, request *GetSpansRequest) (*GetSpansResponse, error)
	GetSpansIter(ctx context.Context, request *GetSpansRequest) *Iter[ResourceSpans]

	// Logs
	GetLogRecords(ctx context.Context, request *GetLogRecordsRequest) (*GetLogRecordsResponse, error)
	GetLogRecordsIter(ctx context.Context, request *GetLogRecordsRequest) *Iter[ResourceLogs]

	// Import
	ImportCheckRule(ctx context.Context, rule *PrometheusAlertRule, dataset *string) (*PrometheusAlertRule, error)
	ImportDashboard(ctx context.Context, dashboard *DashboardDefinition, dataset *string) (*DashboardDefinition, error)
	ImportSyntheticCheck(ctx context.Context, check *SyntheticCheckDefinition, dataset *string) (*SyntheticCheckDefinition, error)
	ImportView(ctx context.Context, view *ViewDefinition, dataset *string) (*ViewDefinition, error)

	// OTLP
	SendLogs(ctx context.Context, logs plog.Logs, dataset *string) error
	SendMetrics(ctx context.Context, metrics pmetric.Metrics, dataset *string) error
	SendTraces(ctx context.Context, traces ptrace.Traces, dataset *string) error

	// Close releases resources associated with the client. Callers should
	// call Close when the client is no longer needed.
	Close(ctx context.Context) error

	// Inner returns the underlying generated client for advanced use cases.
	Inner() *ClientWithResponses
}

Client defines the Dash0 API client interface. Use NewClient to create a concrete implementation.

func NewClient

func NewClient(opts ...ClientOption) (Client, error)

NewClient creates a new Dash0 API client.

Required options:

  • WithAuthToken: The auth token for authentication
  • At least one of WithApiUrl or WithOtlpEndpoint

Example:

client, err := dash0.NewClient(
    dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
    dash0.WithAuthToken("your-auth-token"),
)
Example (ApiAndOtlp)
package main

import (
	"context"
	"log"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	client, err := dash0.NewClient(
		dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
		dash0.WithOtlpEndpoint(dash0.OtlpEncodingJson, "https://ingress.eu-west-1.aws.dash0.com"),
		dash0.WithAuthToken("auth_yourtoken"),
	)
	if err != nil {
		log.Fatal(err)
	}
	defer func() { _ = client.Close(context.Background()) }()
	_ = client
}
Example (ApiOnly)
package main

import (
	"context"
	"fmt"
	"log"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	client, err := dash0.NewClient(
		dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
		dash0.WithAuthToken("auth_yourtoken"),
	)
	if err != nil {
		log.Fatal(err)
	}
	defer func() { _ = client.Close(context.Background()) }()

	dashboards, err := client.ListDashboards(context.Background(), nil)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("Found %d dashboards\n", len(dashboards))
}
Example (FromProfile)
package main

import (
	"context"
	"fmt"
	"log"

	dash0 "github.com/dash0hq/dash0-api-client-go"
	"github.com/dash0hq/dash0-api-client-go/profiles"
)

func main() {
	cfg, err := profiles.ResolveConfiguration("", "")
	if err != nil {
		log.Fatal(err)
	}

	opts := append(cfg.ClientOptions(), dash0.WithUserAgent("my-tool/1.0"))
	client, err := dash0.NewClient(opts...)
	if err != nil {
		log.Fatal(err)
	}
	defer func() { _ = client.Close(context.Background()) }()

	dashboards, err := client.ListDashboards(context.Background(), cfg.DatasetPtr())
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("Found %d dashboards\n", len(dashboards))
}

type ClientInterface

type ClientInterface interface {
	// GetWellKnownOauthAuthorizationServer request
	GetWellKnownOauthAuthorizationServer(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetWellKnownOauthProtectedResource request
	GetWellKnownOauthProtectedResource(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiAlertingCheckRules request
	GetApiAlertingCheckRules(ctx context.Context, params *GetApiAlertingCheckRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiAlertingCheckRulesWithBody request with any body
	PostApiAlertingCheckRulesWithBody(ctx context.Context, params *PostApiAlertingCheckRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiAlertingCheckRules(ctx context.Context, params *PostApiAlertingCheckRulesParams, body PostApiAlertingCheckRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiAlertingCheckRulesOriginOrId request
	DeleteApiAlertingCheckRulesOriginOrId(ctx context.Context, originOrId string, params *DeleteApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiAlertingCheckRulesOriginOrId request
	GetApiAlertingCheckRulesOriginOrId(ctx context.Context, originOrId string, params *GetApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiAlertingCheckRulesOriginOrIdWithBody request with any body
	PutApiAlertingCheckRulesOriginOrIdWithBody(ctx context.Context, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiAlertingCheckRulesOriginOrId(ctx context.Context, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, body PutApiAlertingCheckRulesOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiDashboards request
	GetApiDashboards(ctx context.Context, params *GetApiDashboardsParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiDashboardsWithBody request with any body
	PostApiDashboardsWithBody(ctx context.Context, params *PostApiDashboardsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiDashboards(ctx context.Context, params *PostApiDashboardsParams, body PostApiDashboardsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiDashboardsOriginOrId request
	DeleteApiDashboardsOriginOrId(ctx context.Context, originOrId string, params *DeleteApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiDashboardsOriginOrId request
	GetApiDashboardsOriginOrId(ctx context.Context, originOrId string, params *GetApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiDashboardsOriginOrIdWithBody request with any body
	PutApiDashboardsOriginOrIdWithBody(ctx context.Context, originOrId string, params *PutApiDashboardsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiDashboardsOriginOrId(ctx context.Context, originOrId string, params *PutApiDashboardsOriginOrIdParams, body PutApiDashboardsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiImportCheckRuleWithBody request with any body
	PostApiImportCheckRuleWithBody(ctx context.Context, params *PostApiImportCheckRuleParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiImportCheckRule(ctx context.Context, params *PostApiImportCheckRuleParams, body PostApiImportCheckRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiImportDashboardWithBody request with any body
	PostApiImportDashboardWithBody(ctx context.Context, params *PostApiImportDashboardParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiImportDashboard(ctx context.Context, params *PostApiImportDashboardParams, body PostApiImportDashboardJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiImportSyntheticCheckWithBody request with any body
	PostApiImportSyntheticCheckWithBody(ctx context.Context, params *PostApiImportSyntheticCheckParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiImportSyntheticCheck(ctx context.Context, params *PostApiImportSyntheticCheckParams, body PostApiImportSyntheticCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiImportViewWithBody request with any body
	PostApiImportViewWithBody(ctx context.Context, params *PostApiImportViewParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiImportView(ctx context.Context, params *PostApiImportViewParams, body PostApiImportViewJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiLogsWithBody request with any body
	PostApiLogsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiLogs(ctx context.Context, body PostApiLogsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiMembers request
	GetApiMembers(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiMembersWithBody request with any body
	PostApiMembersWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiMembers(ctx context.Context, body PostApiMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiMembersMemberID request
	DeleteApiMembersMemberID(ctx context.Context, memberID string, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiRecordingRuleGroups request
	GetApiRecordingRuleGroups(ctx context.Context, params *GetApiRecordingRuleGroupsParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiRecordingRuleGroupsWithBody request with any body
	PostApiRecordingRuleGroupsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiRecordingRuleGroups(ctx context.Context, body PostApiRecordingRuleGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiRecordingRuleGroupsOriginOrId request
	DeleteApiRecordingRuleGroupsOriginOrId(ctx context.Context, originOrId string, params *DeleteApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiRecordingRuleGroupsOriginOrId request
	GetApiRecordingRuleGroupsOriginOrId(ctx context.Context, originOrId string, params *GetApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiRecordingRuleGroupsOriginOrIdWithBody request with any body
	PutApiRecordingRuleGroupsOriginOrIdWithBody(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiRecordingRuleGroupsOriginOrId(ctx context.Context, originOrId string, body PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiRecordingRuleGroupsOriginOrIdVersionsVersion request
	GetApiRecordingRuleGroupsOriginOrIdVersionsVersion(ctx context.Context, originOrId string, version int64, params *GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiSamplingRules request
	GetApiSamplingRules(ctx context.Context, params *GetApiSamplingRulesParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiSamplingRulesWithBody request with any body
	PostApiSamplingRulesWithBody(ctx context.Context, params *PostApiSamplingRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiSamplingRules(ctx context.Context, params *PostApiSamplingRulesParams, body PostApiSamplingRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiSamplingRulesOriginOrId request
	DeleteApiSamplingRulesOriginOrId(ctx context.Context, originOrId string, params *DeleteApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiSamplingRulesOriginOrId request
	GetApiSamplingRulesOriginOrId(ctx context.Context, originOrId string, params *GetApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiSamplingRulesOriginOrIdWithBody request with any body
	PutApiSamplingRulesOriginOrIdWithBody(ctx context.Context, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiSamplingRulesOriginOrId(ctx context.Context, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, body PutApiSamplingRulesOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiSpansWithBody request with any body
	PostApiSpansWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiSpans(ctx context.Context, body PostApiSpansJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiSqlWithBody request with any body
	PostApiSqlWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiSql(ctx context.Context, body PostApiSqlJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiSyntheticChecks request
	GetApiSyntheticChecks(ctx context.Context, params *GetApiSyntheticChecksParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiSyntheticChecksWithBody request with any body
	PostApiSyntheticChecksWithBody(ctx context.Context, params *PostApiSyntheticChecksParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiSyntheticChecks(ctx context.Context, params *PostApiSyntheticChecksParams, body PostApiSyntheticChecksJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiSyntheticChecksLocations request
	GetApiSyntheticChecksLocations(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiSyntheticChecksTestWithBody request with any body
	PostApiSyntheticChecksTestWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiSyntheticChecksTest(ctx context.Context, body PostApiSyntheticChecksTestJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiSyntheticChecksOriginOrId request
	DeleteApiSyntheticChecksOriginOrId(ctx context.Context, originOrId string, params *DeleteApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiSyntheticChecksOriginOrId request
	GetApiSyntheticChecksOriginOrId(ctx context.Context, originOrId string, params *GetApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiSyntheticChecksOriginOrIdWithBody request with any body
	PutApiSyntheticChecksOriginOrIdWithBody(ctx context.Context, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiSyntheticChecksOriginOrId(ctx context.Context, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, body PutApiSyntheticChecksOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiTeams request
	GetApiTeams(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiTeamsWithBody request with any body
	PostApiTeamsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiTeams(ctx context.Context, body PostApiTeamsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiTeamsOriginOrId request
	DeleteApiTeamsOriginOrId(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiTeamsOriginOrId request
	GetApiTeamsOriginOrId(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiTeamsOriginOrIdDisplayWithBody request with any body
	PutApiTeamsOriginOrIdDisplayWithBody(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiTeamsOriginOrIdDisplay(ctx context.Context, originOrId string, body PutApiTeamsOriginOrIdDisplayJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiTeamsOriginOrIdMembersWithBody request with any body
	PostApiTeamsOriginOrIdMembersWithBody(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiTeamsOriginOrIdMembers(ctx context.Context, originOrId string, body PostApiTeamsOriginOrIdMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiTeamsOriginOrIdMembersMemberID request
	DeleteApiTeamsOriginOrIdMembersMemberID(ctx context.Context, originOrId string, memberID string, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiViews request
	GetApiViews(ctx context.Context, params *GetApiViewsParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostApiViewsWithBody request with any body
	PostApiViewsWithBody(ctx context.Context, params *PostApiViewsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostApiViews(ctx context.Context, params *PostApiViewsParams, body PostApiViewsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// DeleteApiViewsOriginOrId request
	DeleteApiViewsOriginOrId(ctx context.Context, originOrId string, params *DeleteApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetApiViewsOriginOrId request
	GetApiViewsOriginOrId(ctx context.Context, originOrId string, params *GetApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PutApiViewsOriginOrIdWithBody request with any body
	PutApiViewsOriginOrIdWithBody(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PutApiViewsOriginOrId(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, body PutApiViewsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// GetOauthAuthorize request
	GetOauthAuthorize(ctx context.Context, params *GetOauthAuthorizeParams, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostOauthRegisterWithBody request with any body
	PostOauthRegisterWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostOauthRegister(ctx context.Context, body PostOauthRegisterJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostOauthRevokeWithBody request with any body
	PostOauthRevokeWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostOauthRevokeWithFormdataBody(ctx context.Context, body PostOauthRevokeFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// PostOauthTokenWithBody request with any body
	PostOauthTokenWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

	PostOauthTokenWithFormdataBody(ctx context.Context, body PostOauthTokenFormdataRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)
}

The interface specification for the client above.

type ClientOption

type ClientOption func(*clientConfig)

ClientOption configures a Dash0 client.

func WithApiUrl

func WithApiUrl(url string) ClientOption

WithApiUrl sets the Dash0 API URL. This is required for REST API operations (dashboards, check rules, etc.). Examples:

func WithAuthToken

func WithAuthToken(authToken string) ClientOption

WithAuthToken sets the auth token for authentication. This is required for all API requests.

func WithHTTPClient

func WithHTTPClient(client *http.Client) ClientOption

WithHTTPClient sets a custom HTTP client. The client's transport will be wrapped with rate limiting middleware. Other settings like CheckRedirect and Jar will be preserved.

This option conflicts with WithTransport.

func WithMaxConcurrentRequests

func WithMaxConcurrentRequests(n int64) ClientOption

WithMaxConcurrentRequests sets the maximum number of concurrent API calls. The value must be between 1 and 10 (inclusive). Values outside this range will be clamped. Default is 3.

This option conflicts with WithTransport.

func WithMaxRetries

func WithMaxRetries(n int) ClientOption

WithMaxRetries sets the maximum number of retries for failed requests. Only idempotent requests (GET, PUT, DELETE) and requests marked with withIdempotent context are retried. Default is 1. Maximum is 5. Set to 0 to disable retries.

This option conflicts with WithTransport.

Example:

client, _ := dash0.NewClient(
    dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
    dash0.WithAuthToken("your-auth-token"),
    dash0.WithMaxRetries(3),
)

func WithOtlpEndpoint added in v1.2.0

func WithOtlpEndpoint(encoding OtlpEncoding, url string) ClientOption

WithOtlpEndpoint configures the client to push telemetry data via OTLP/HTTP. The encoding parameter specifies the wire format; currently only OtlpEncodingJson is supported. The url is the base OTLP endpoint (e.g., "https://otlp.example.com:4318"); signal-specific paths like /v1/traces are appended automatically.

This option is optional. If not set, SendTraces, SendMetrics, and SendLogs will return an error.

func WithRetryWaitMax

func WithRetryWaitMax(d time.Duration) ClientOption

WithRetryWaitMax sets the maximum wait time between retries. Default is 30s. The backoff will not exceed this value.

This option conflicts with WithTransport.

func WithRetryWaitMin

func WithRetryWaitMin(d time.Duration) ClientOption

WithRetryWaitMin sets the minimum wait time between retries. Default is 500ms. The actual wait time uses exponential backoff starting from this value.

This option conflicts with WithTransport.

func WithTimeout

func WithTimeout(d time.Duration) ClientOption

WithTimeout sets the HTTP request timeout. Default is 30 seconds.

When used with WithTransport, this overrides the timeout configured on the Transport.

func WithTransport added in v1.8.0

func WithTransport(t *Transport) ClientOption

WithTransport configures the client to use a pre-built Transport for rate limiting and retry. When set, transport-level ClientOption functions (WithMaxRetries, WithRetryWaitMin, WithRetryWaitMax, WithMaxConcurrentRequests, and WithHTTPClient) must not be used. NewClient returns an error if both WithTransport and any of these options are provided.

WithTimeout remains compatible: when set alongside WithTransport it overrides the timeout configured on the Transport.

Example:

t := dash0.NewTransport(
    dash0.WithTransportMaxRetries(3),
)
client, err := dash0.NewClient(
    dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
    dash0.WithAuthToken("auth_yourtoken"),
    dash0.WithTransport(t),
)
Example
package main

import (
	"context"
	"fmt"
	"log"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	t := dash0.NewTransport(
		dash0.WithTransportMaxRetries(3),
		dash0.WithTransportMaxConcurrentRequests(5),
	)

	// Use the same transport for both a raw HTTP client and a typed client.
	httpClient := t.HTTPClient()
	_ = httpClient

	client, err := dash0.NewClient(
		dash0.WithApiUrl("https://api.eu-west-1.aws.dash0.com"),
		dash0.WithAuthToken("auth_yourtoken"),
		dash0.WithTransport(t),
	)
	if err != nil {
		log.Fatal(err)
	}
	defer func() { _ = client.Close(context.Background()) }()
	fmt.Println(client != nil)
}
Output:
true

func WithUserAgent

func WithUserAgent(ua string) ClientOption

WithUserAgent sets a custom User-Agent header. Default is "dash0-api-client-go/" followed by the current library version.

type ClientWithResponses

type ClientWithResponses struct {
	ClientInterface
}

ClientWithResponses builds on ClientInterface to offer response payloads

func NewClientWithResponses

func NewClientWithResponses(server string, opts ...generatedClientOption) (*ClientWithResponses, error)

NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling

func (*ClientWithResponses) DeleteApiAlertingCheckRulesOriginOrIdWithResponse

func (c *ClientWithResponses) DeleteApiAlertingCheckRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiAlertingCheckRulesOriginOrIdResponse, error)

DeleteApiAlertingCheckRulesOriginOrIdWithResponse request returning *DeleteApiAlertingCheckRulesOriginOrIdResponse

func (*ClientWithResponses) DeleteApiDashboardsOriginOrIdWithResponse

func (c *ClientWithResponses) DeleteApiDashboardsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiDashboardsOriginOrIdResponse, error)

DeleteApiDashboardsOriginOrIdWithResponse request returning *DeleteApiDashboardsOriginOrIdResponse

func (*ClientWithResponses) DeleteApiMembersMemberIDWithResponse added in v1.4.0

func (c *ClientWithResponses) DeleteApiMembersMemberIDWithResponse(ctx context.Context, memberID string, reqEditors ...RequestEditorFn) (*DeleteApiMembersMemberIDResponse, error)

DeleteApiMembersMemberIDWithResponse request returning *DeleteApiMembersMemberIDResponse

func (*ClientWithResponses) DeleteApiRecordingRuleGroupsOriginOrIdWithResponse added in v1.6.0

func (c *ClientWithResponses) DeleteApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiRecordingRuleGroupsOriginOrIdResponse, error)

DeleteApiRecordingRuleGroupsOriginOrIdWithResponse request returning *DeleteApiRecordingRuleGroupsOriginOrIdResponse

func (*ClientWithResponses) DeleteApiSamplingRulesOriginOrIdWithResponse added in v1.1.0

func (c *ClientWithResponses) DeleteApiSamplingRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiSamplingRulesOriginOrIdResponse, error)

DeleteApiSamplingRulesOriginOrIdWithResponse request returning *DeleteApiSamplingRulesOriginOrIdResponse

func (*ClientWithResponses) DeleteApiSyntheticChecksOriginOrIdWithResponse

func (c *ClientWithResponses) DeleteApiSyntheticChecksOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiSyntheticChecksOriginOrIdResponse, error)

DeleteApiSyntheticChecksOriginOrIdWithResponse request returning *DeleteApiSyntheticChecksOriginOrIdResponse

func (*ClientWithResponses) DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse added in v1.4.0

func (c *ClientWithResponses) DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse(ctx context.Context, originOrId string, memberID string, reqEditors ...RequestEditorFn) (*DeleteApiTeamsOriginOrIdMembersMemberIDResponse, error)

DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse request returning *DeleteApiTeamsOriginOrIdMembersMemberIDResponse

func (*ClientWithResponses) DeleteApiTeamsOriginOrIdWithResponse added in v1.4.0

func (c *ClientWithResponses) DeleteApiTeamsOriginOrIdWithResponse(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*DeleteApiTeamsOriginOrIdResponse, error)

DeleteApiTeamsOriginOrIdWithResponse request returning *DeleteApiTeamsOriginOrIdResponse

func (*ClientWithResponses) DeleteApiViewsOriginOrIdWithResponse

func (c *ClientWithResponses) DeleteApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiViewsOriginOrIdResponse, error)

DeleteApiViewsOriginOrIdWithResponse request returning *DeleteApiViewsOriginOrIdResponse

func (*ClientWithResponses) GetApiAlertingCheckRulesOriginOrIdWithResponse

func (c *ClientWithResponses) GetApiAlertingCheckRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiAlertingCheckRulesOriginOrIdResponse, error)

GetApiAlertingCheckRulesOriginOrIdWithResponse request returning *GetApiAlertingCheckRulesOriginOrIdResponse

func (*ClientWithResponses) GetApiAlertingCheckRulesWithResponse

func (c *ClientWithResponses) GetApiAlertingCheckRulesWithResponse(ctx context.Context, params *GetApiAlertingCheckRulesParams, reqEditors ...RequestEditorFn) (*GetApiAlertingCheckRulesResponse, error)

GetApiAlertingCheckRulesWithResponse request returning *GetApiAlertingCheckRulesResponse

func (*ClientWithResponses) GetApiDashboardsOriginOrIdWithResponse

func (c *ClientWithResponses) GetApiDashboardsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiDashboardsOriginOrIdResponse, error)

GetApiDashboardsOriginOrIdWithResponse request returning *GetApiDashboardsOriginOrIdResponse

func (*ClientWithResponses) GetApiDashboardsWithResponse

func (c *ClientWithResponses) GetApiDashboardsWithResponse(ctx context.Context, params *GetApiDashboardsParams, reqEditors ...RequestEditorFn) (*GetApiDashboardsResponse, error)

GetApiDashboardsWithResponse request returning *GetApiDashboardsResponse

func (*ClientWithResponses) GetApiMembersWithResponse added in v1.4.0

func (c *ClientWithResponses) GetApiMembersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiMembersResponse, error)

GetApiMembersWithResponse request returning *GetApiMembersResponse

func (*ClientWithResponses) GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse added in v1.6.0

func (c *ClientWithResponses) GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse(ctx context.Context, originOrId string, version int64, params *GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse, error)

GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse request returning *GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse

func (*ClientWithResponses) GetApiRecordingRuleGroupsOriginOrIdWithResponse added in v1.6.0

func (c *ClientWithResponses) GetApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsOriginOrIdResponse, error)

GetApiRecordingRuleGroupsOriginOrIdWithResponse request returning *GetApiRecordingRuleGroupsOriginOrIdResponse

func (*ClientWithResponses) GetApiRecordingRuleGroupsWithResponse added in v1.6.0

func (c *ClientWithResponses) GetApiRecordingRuleGroupsWithResponse(ctx context.Context, params *GetApiRecordingRuleGroupsParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsResponse, error)

GetApiRecordingRuleGroupsWithResponse request returning *GetApiRecordingRuleGroupsResponse

func (*ClientWithResponses) GetApiSamplingRulesOriginOrIdWithResponse added in v1.1.0

func (c *ClientWithResponses) GetApiSamplingRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiSamplingRulesOriginOrIdResponse, error)

GetApiSamplingRulesOriginOrIdWithResponse request returning *GetApiSamplingRulesOriginOrIdResponse

func (*ClientWithResponses) GetApiSamplingRulesWithResponse added in v1.1.0

func (c *ClientWithResponses) GetApiSamplingRulesWithResponse(ctx context.Context, params *GetApiSamplingRulesParams, reqEditors ...RequestEditorFn) (*GetApiSamplingRulesResponse, error)

GetApiSamplingRulesWithResponse request returning *GetApiSamplingRulesResponse

func (*ClientWithResponses) GetApiSyntheticChecksLocationsWithResponse added in v1.6.0

func (c *ClientWithResponses) GetApiSyntheticChecksLocationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksLocationsResponse, error)

GetApiSyntheticChecksLocationsWithResponse request returning *GetApiSyntheticChecksLocationsResponse

func (*ClientWithResponses) GetApiSyntheticChecksOriginOrIdWithResponse

func (c *ClientWithResponses) GetApiSyntheticChecksOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksOriginOrIdResponse, error)

GetApiSyntheticChecksOriginOrIdWithResponse request returning *GetApiSyntheticChecksOriginOrIdResponse

func (*ClientWithResponses) GetApiSyntheticChecksWithResponse

func (c *ClientWithResponses) GetApiSyntheticChecksWithResponse(ctx context.Context, params *GetApiSyntheticChecksParams, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksResponse, error)

GetApiSyntheticChecksWithResponse request returning *GetApiSyntheticChecksResponse

func (*ClientWithResponses) GetApiTeamsOriginOrIdWithResponse added in v1.4.0

func (c *ClientWithResponses) GetApiTeamsOriginOrIdWithResponse(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*GetApiTeamsOriginOrIdResponse, error)

GetApiTeamsOriginOrIdWithResponse request returning *GetApiTeamsOriginOrIdResponse

func (*ClientWithResponses) GetApiTeamsWithResponse added in v1.4.0

func (c *ClientWithResponses) GetApiTeamsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiTeamsResponse, error)

GetApiTeamsWithResponse request returning *GetApiTeamsResponse

func (*ClientWithResponses) GetApiViewsOriginOrIdWithResponse

func (c *ClientWithResponses) GetApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiViewsOriginOrIdResponse, error)

GetApiViewsOriginOrIdWithResponse request returning *GetApiViewsOriginOrIdResponse

func (*ClientWithResponses) GetApiViewsWithResponse

func (c *ClientWithResponses) GetApiViewsWithResponse(ctx context.Context, params *GetApiViewsParams, reqEditors ...RequestEditorFn) (*GetApiViewsResponse, error)

GetApiViewsWithResponse request returning *GetApiViewsResponse

func (*ClientWithResponses) GetOauthAuthorizeWithResponse added in v1.6.0

func (c *ClientWithResponses) GetOauthAuthorizeWithResponse(ctx context.Context, params *GetOauthAuthorizeParams, reqEditors ...RequestEditorFn) (*GetOauthAuthorizeResponse, error)

GetOauthAuthorizeWithResponse request returning *GetOauthAuthorizeResponse

func (*ClientWithResponses) GetWellKnownOauthAuthorizationServerWithResponse added in v1.6.0

func (c *ClientWithResponses) GetWellKnownOauthAuthorizationServerWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetWellKnownOauthAuthorizationServerResponse, error)

GetWellKnownOauthAuthorizationServerWithResponse request returning *GetWellKnownOauthAuthorizationServerResponse

func (*ClientWithResponses) GetWellKnownOauthProtectedResourceWithResponse added in v1.6.0

func (c *ClientWithResponses) GetWellKnownOauthProtectedResourceWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetWellKnownOauthProtectedResourceResponse, error)

GetWellKnownOauthProtectedResourceWithResponse request returning *GetWellKnownOauthProtectedResourceResponse

func (*ClientWithResponses) PostApiAlertingCheckRulesWithBodyWithResponse

func (c *ClientWithResponses) PostApiAlertingCheckRulesWithBodyWithResponse(ctx context.Context, params *PostApiAlertingCheckRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiAlertingCheckRulesResponse, error)

PostApiAlertingCheckRulesWithBodyWithResponse request with arbitrary body returning *PostApiAlertingCheckRulesResponse

func (*ClientWithResponses) PostApiDashboardsWithBodyWithResponse

func (c *ClientWithResponses) PostApiDashboardsWithBodyWithResponse(ctx context.Context, params *PostApiDashboardsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiDashboardsResponse, error)

PostApiDashboardsWithBodyWithResponse request with arbitrary body returning *PostApiDashboardsResponse

func (*ClientWithResponses) PostApiDashboardsWithResponse

func (*ClientWithResponses) PostApiImportCheckRuleWithBodyWithResponse

func (c *ClientWithResponses) PostApiImportCheckRuleWithBodyWithResponse(ctx context.Context, params *PostApiImportCheckRuleParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportCheckRuleResponse, error)

PostApiImportCheckRuleWithBodyWithResponse request with arbitrary body returning *PostApiImportCheckRuleResponse

func (*ClientWithResponses) PostApiImportCheckRuleWithResponse

func (*ClientWithResponses) PostApiImportDashboardWithBodyWithResponse

func (c *ClientWithResponses) PostApiImportDashboardWithBodyWithResponse(ctx context.Context, params *PostApiImportDashboardParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportDashboardResponse, error)

PostApiImportDashboardWithBodyWithResponse request with arbitrary body returning *PostApiImportDashboardResponse

func (*ClientWithResponses) PostApiImportDashboardWithResponse

func (*ClientWithResponses) PostApiImportSyntheticCheckWithBodyWithResponse

func (c *ClientWithResponses) PostApiImportSyntheticCheckWithBodyWithResponse(ctx context.Context, params *PostApiImportSyntheticCheckParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportSyntheticCheckResponse, error)

PostApiImportSyntheticCheckWithBodyWithResponse request with arbitrary body returning *PostApiImportSyntheticCheckResponse

func (*ClientWithResponses) PostApiImportViewWithBodyWithResponse

func (c *ClientWithResponses) PostApiImportViewWithBodyWithResponse(ctx context.Context, params *PostApiImportViewParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportViewResponse, error)

PostApiImportViewWithBodyWithResponse request with arbitrary body returning *PostApiImportViewResponse

func (*ClientWithResponses) PostApiImportViewWithResponse

func (*ClientWithResponses) PostApiLogsWithBodyWithResponse

func (c *ClientWithResponses) PostApiLogsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiLogsResponse, error)

PostApiLogsWithBodyWithResponse request with arbitrary body returning *PostApiLogsResponse

func (*ClientWithResponses) PostApiLogsWithResponse

func (c *ClientWithResponses) PostApiLogsWithResponse(ctx context.Context, body PostApiLogsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiLogsResponse, error)

func (*ClientWithResponses) PostApiMembersWithBodyWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiMembersWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiMembersResponse, error)

PostApiMembersWithBodyWithResponse request with arbitrary body returning *PostApiMembersResponse

func (*ClientWithResponses) PostApiMembersWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiMembersWithResponse(ctx context.Context, body PostApiMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiMembersResponse, error)

func (*ClientWithResponses) PostApiRecordingRuleGroupsWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostApiRecordingRuleGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiRecordingRuleGroupsResponse, error)

PostApiRecordingRuleGroupsWithBodyWithResponse request with arbitrary body returning *PostApiRecordingRuleGroupsResponse

func (*ClientWithResponses) PostApiRecordingRuleGroupsWithResponse added in v1.6.0

func (c *ClientWithResponses) PostApiRecordingRuleGroupsWithResponse(ctx context.Context, body PostApiRecordingRuleGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiRecordingRuleGroupsResponse, error)

func (*ClientWithResponses) PostApiSamplingRulesWithBodyWithResponse added in v1.1.0

func (c *ClientWithResponses) PostApiSamplingRulesWithBodyWithResponse(ctx context.Context, params *PostApiSamplingRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSamplingRulesResponse, error)

PostApiSamplingRulesWithBodyWithResponse request with arbitrary body returning *PostApiSamplingRulesResponse

func (*ClientWithResponses) PostApiSamplingRulesWithResponse added in v1.1.0

func (*ClientWithResponses) PostApiSpansWithBodyWithResponse

func (c *ClientWithResponses) PostApiSpansWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSpansResponse, error)

PostApiSpansWithBodyWithResponse request with arbitrary body returning *PostApiSpansResponse

func (*ClientWithResponses) PostApiSpansWithResponse

func (c *ClientWithResponses) PostApiSpansWithResponse(ctx context.Context, body PostApiSpansJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSpansResponse, error)

func (*ClientWithResponses) PostApiSqlWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostApiSqlWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSqlResponse, error)

PostApiSqlWithBodyWithResponse request with arbitrary body returning *PostApiSqlResponse

func (*ClientWithResponses) PostApiSqlWithResponse added in v1.6.0

func (c *ClientWithResponses) PostApiSqlWithResponse(ctx context.Context, body PostApiSqlJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSqlResponse, error)

func (*ClientWithResponses) PostApiSyntheticChecksTestWithBodyWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiSyntheticChecksTestWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksTestResponse, error)

PostApiSyntheticChecksTestWithBodyWithResponse request with arbitrary body returning *PostApiSyntheticChecksTestResponse

func (*ClientWithResponses) PostApiSyntheticChecksTestWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiSyntheticChecksTestWithResponse(ctx context.Context, body PostApiSyntheticChecksTestJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksTestResponse, error)

func (*ClientWithResponses) PostApiSyntheticChecksWithBodyWithResponse

func (c *ClientWithResponses) PostApiSyntheticChecksWithBodyWithResponse(ctx context.Context, params *PostApiSyntheticChecksParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksResponse, error)

PostApiSyntheticChecksWithBodyWithResponse request with arbitrary body returning *PostApiSyntheticChecksResponse

func (*ClientWithResponses) PostApiSyntheticChecksWithResponse

func (*ClientWithResponses) PostApiTeamsOriginOrIdMembersWithBodyWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiTeamsOriginOrIdMembersWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiTeamsOriginOrIdMembersResponse, error)

PostApiTeamsOriginOrIdMembersWithBodyWithResponse request with arbitrary body returning *PostApiTeamsOriginOrIdMembersResponse

func (*ClientWithResponses) PostApiTeamsOriginOrIdMembersWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiTeamsOriginOrIdMembersWithResponse(ctx context.Context, originOrId string, body PostApiTeamsOriginOrIdMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiTeamsOriginOrIdMembersResponse, error)

func (*ClientWithResponses) PostApiTeamsWithBodyWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiTeamsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiTeamsResponse, error)

PostApiTeamsWithBodyWithResponse request with arbitrary body returning *PostApiTeamsResponse

func (*ClientWithResponses) PostApiTeamsWithResponse added in v1.4.0

func (c *ClientWithResponses) PostApiTeamsWithResponse(ctx context.Context, body PostApiTeamsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiTeamsResponse, error)

func (*ClientWithResponses) PostApiViewsWithBodyWithResponse

func (c *ClientWithResponses) PostApiViewsWithBodyWithResponse(ctx context.Context, params *PostApiViewsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiViewsResponse, error)

PostApiViewsWithBodyWithResponse request with arbitrary body returning *PostApiViewsResponse

func (*ClientWithResponses) PostApiViewsWithResponse

func (c *ClientWithResponses) PostApiViewsWithResponse(ctx context.Context, params *PostApiViewsParams, body PostApiViewsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiViewsResponse, error)

func (*ClientWithResponses) PostOauthRegisterWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthRegisterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthRegisterResponse, error)

PostOauthRegisterWithBodyWithResponse request with arbitrary body returning *PostOauthRegisterResponse

func (*ClientWithResponses) PostOauthRegisterWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthRegisterWithResponse(ctx context.Context, body PostOauthRegisterJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOauthRegisterResponse, error)

func (*ClientWithResponses) PostOauthRevokeWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthRevokeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthRevokeResponse, error)

PostOauthRevokeWithBodyWithResponse request with arbitrary body returning *PostOauthRevokeResponse

func (*ClientWithResponses) PostOauthRevokeWithFormdataBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthRevokeWithFormdataBodyWithResponse(ctx context.Context, body PostOauthRevokeFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostOauthRevokeResponse, error)

func (*ClientWithResponses) PostOauthTokenWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthTokenWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthTokenResponse, error)

PostOauthTokenWithBodyWithResponse request with arbitrary body returning *PostOauthTokenResponse

func (*ClientWithResponses) PostOauthTokenWithFormdataBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PostOauthTokenWithFormdataBodyWithResponse(ctx context.Context, body PostOauthTokenFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostOauthTokenResponse, error)

func (*ClientWithResponses) PutApiAlertingCheckRulesOriginOrIdWithBodyWithResponse

func (c *ClientWithResponses) PutApiAlertingCheckRulesOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiAlertingCheckRulesOriginOrIdResponse, error)

PutApiAlertingCheckRulesOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiAlertingCheckRulesOriginOrIdResponse

func (*ClientWithResponses) PutApiDashboardsOriginOrIdWithBodyWithResponse

func (c *ClientWithResponses) PutApiDashboardsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiDashboardsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiDashboardsOriginOrIdResponse, error)

PutApiDashboardsOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiDashboardsOriginOrIdResponse

func (*ClientWithResponses) PutApiDashboardsOriginOrIdWithResponse

func (*ClientWithResponses) PutApiRecordingRuleGroupsOriginOrIdWithBodyWithResponse added in v1.6.0

func (c *ClientWithResponses) PutApiRecordingRuleGroupsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiRecordingRuleGroupsOriginOrIdResponse, error)

PutApiRecordingRuleGroupsOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiRecordingRuleGroupsOriginOrIdResponse

func (*ClientWithResponses) PutApiRecordingRuleGroupsOriginOrIdWithResponse added in v1.6.0

func (c *ClientWithResponses) PutApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, body PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiRecordingRuleGroupsOriginOrIdResponse, error)

func (*ClientWithResponses) PutApiSamplingRulesOriginOrIdWithBodyWithResponse added in v1.1.0

func (c *ClientWithResponses) PutApiSamplingRulesOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiSamplingRulesOriginOrIdResponse, error)

PutApiSamplingRulesOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiSamplingRulesOriginOrIdResponse

func (*ClientWithResponses) PutApiSamplingRulesOriginOrIdWithResponse added in v1.1.0

func (*ClientWithResponses) PutApiSyntheticChecksOriginOrIdWithBodyWithResponse

func (c *ClientWithResponses) PutApiSyntheticChecksOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiSyntheticChecksOriginOrIdResponse, error)

PutApiSyntheticChecksOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiSyntheticChecksOriginOrIdResponse

func (*ClientWithResponses) PutApiTeamsOriginOrIdDisplayWithBodyWithResponse added in v1.4.0

func (c *ClientWithResponses) PutApiTeamsOriginOrIdDisplayWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiTeamsOriginOrIdDisplayResponse, error)

PutApiTeamsOriginOrIdDisplayWithBodyWithResponse request with arbitrary body returning *PutApiTeamsOriginOrIdDisplayResponse

func (*ClientWithResponses) PutApiTeamsOriginOrIdDisplayWithResponse added in v1.4.0

func (c *ClientWithResponses) PutApiTeamsOriginOrIdDisplayWithResponse(ctx context.Context, originOrId string, body PutApiTeamsOriginOrIdDisplayJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiTeamsOriginOrIdDisplayResponse, error)

func (*ClientWithResponses) PutApiViewsOriginOrIdWithBodyWithResponse

func (c *ClientWithResponses) PutApiViewsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiViewsOriginOrIdResponse, error)

PutApiViewsOriginOrIdWithBodyWithResponse request with arbitrary body returning *PutApiViewsOriginOrIdResponse

func (*ClientWithResponses) PutApiViewsOriginOrIdWithResponse

func (c *ClientWithResponses) PutApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, body PutApiViewsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiViewsOriginOrIdResponse, error)

type ClientWithResponsesInterface

type ClientWithResponsesInterface interface {
	// GetWellKnownOauthAuthorizationServerWithResponse request
	GetWellKnownOauthAuthorizationServerWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetWellKnownOauthAuthorizationServerResponse, error)

	// GetWellKnownOauthProtectedResourceWithResponse request
	GetWellKnownOauthProtectedResourceWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetWellKnownOauthProtectedResourceResponse, error)

	// GetApiAlertingCheckRulesWithResponse request
	GetApiAlertingCheckRulesWithResponse(ctx context.Context, params *GetApiAlertingCheckRulesParams, reqEditors ...RequestEditorFn) (*GetApiAlertingCheckRulesResponse, error)

	// PostApiAlertingCheckRulesWithBodyWithResponse request with any body
	PostApiAlertingCheckRulesWithBodyWithResponse(ctx context.Context, params *PostApiAlertingCheckRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiAlertingCheckRulesResponse, error)

	PostApiAlertingCheckRulesWithResponse(ctx context.Context, params *PostApiAlertingCheckRulesParams, body PostApiAlertingCheckRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiAlertingCheckRulesResponse, error)

	// DeleteApiAlertingCheckRulesOriginOrIdWithResponse request
	DeleteApiAlertingCheckRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiAlertingCheckRulesOriginOrIdResponse, error)

	// GetApiAlertingCheckRulesOriginOrIdWithResponse request
	GetApiAlertingCheckRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiAlertingCheckRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiAlertingCheckRulesOriginOrIdResponse, error)

	// PutApiAlertingCheckRulesOriginOrIdWithBodyWithResponse request with any body
	PutApiAlertingCheckRulesOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiAlertingCheckRulesOriginOrIdResponse, error)

	PutApiAlertingCheckRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiAlertingCheckRulesOriginOrIdParams, body PutApiAlertingCheckRulesOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiAlertingCheckRulesOriginOrIdResponse, error)

	// GetApiDashboardsWithResponse request
	GetApiDashboardsWithResponse(ctx context.Context, params *GetApiDashboardsParams, reqEditors ...RequestEditorFn) (*GetApiDashboardsResponse, error)

	// PostApiDashboardsWithBodyWithResponse request with any body
	PostApiDashboardsWithBodyWithResponse(ctx context.Context, params *PostApiDashboardsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiDashboardsResponse, error)

	PostApiDashboardsWithResponse(ctx context.Context, params *PostApiDashboardsParams, body PostApiDashboardsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiDashboardsResponse, error)

	// DeleteApiDashboardsOriginOrIdWithResponse request
	DeleteApiDashboardsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiDashboardsOriginOrIdResponse, error)

	// GetApiDashboardsOriginOrIdWithResponse request
	GetApiDashboardsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiDashboardsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiDashboardsOriginOrIdResponse, error)

	// PutApiDashboardsOriginOrIdWithBodyWithResponse request with any body
	PutApiDashboardsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiDashboardsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiDashboardsOriginOrIdResponse, error)

	PutApiDashboardsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiDashboardsOriginOrIdParams, body PutApiDashboardsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiDashboardsOriginOrIdResponse, error)

	// PostApiImportCheckRuleWithBodyWithResponse request with any body
	PostApiImportCheckRuleWithBodyWithResponse(ctx context.Context, params *PostApiImportCheckRuleParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportCheckRuleResponse, error)

	PostApiImportCheckRuleWithResponse(ctx context.Context, params *PostApiImportCheckRuleParams, body PostApiImportCheckRuleJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiImportCheckRuleResponse, error)

	// PostApiImportDashboardWithBodyWithResponse request with any body
	PostApiImportDashboardWithBodyWithResponse(ctx context.Context, params *PostApiImportDashboardParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportDashboardResponse, error)

	PostApiImportDashboardWithResponse(ctx context.Context, params *PostApiImportDashboardParams, body PostApiImportDashboardJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiImportDashboardResponse, error)

	// PostApiImportSyntheticCheckWithBodyWithResponse request with any body
	PostApiImportSyntheticCheckWithBodyWithResponse(ctx context.Context, params *PostApiImportSyntheticCheckParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportSyntheticCheckResponse, error)

	PostApiImportSyntheticCheckWithResponse(ctx context.Context, params *PostApiImportSyntheticCheckParams, body PostApiImportSyntheticCheckJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiImportSyntheticCheckResponse, error)

	// PostApiImportViewWithBodyWithResponse request with any body
	PostApiImportViewWithBodyWithResponse(ctx context.Context, params *PostApiImportViewParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiImportViewResponse, error)

	PostApiImportViewWithResponse(ctx context.Context, params *PostApiImportViewParams, body PostApiImportViewJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiImportViewResponse, error)

	// PostApiLogsWithBodyWithResponse request with any body
	PostApiLogsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiLogsResponse, error)

	PostApiLogsWithResponse(ctx context.Context, body PostApiLogsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiLogsResponse, error)

	// GetApiMembersWithResponse request
	GetApiMembersWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiMembersResponse, error)

	// PostApiMembersWithBodyWithResponse request with any body
	PostApiMembersWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiMembersResponse, error)

	PostApiMembersWithResponse(ctx context.Context, body PostApiMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiMembersResponse, error)

	// DeleteApiMembersMemberIDWithResponse request
	DeleteApiMembersMemberIDWithResponse(ctx context.Context, memberID string, reqEditors ...RequestEditorFn) (*DeleteApiMembersMemberIDResponse, error)

	// GetApiRecordingRuleGroupsWithResponse request
	GetApiRecordingRuleGroupsWithResponse(ctx context.Context, params *GetApiRecordingRuleGroupsParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsResponse, error)

	// PostApiRecordingRuleGroupsWithBodyWithResponse request with any body
	PostApiRecordingRuleGroupsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiRecordingRuleGroupsResponse, error)

	PostApiRecordingRuleGroupsWithResponse(ctx context.Context, body PostApiRecordingRuleGroupsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiRecordingRuleGroupsResponse, error)

	// DeleteApiRecordingRuleGroupsOriginOrIdWithResponse request
	DeleteApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiRecordingRuleGroupsOriginOrIdResponse, error)

	// GetApiRecordingRuleGroupsOriginOrIdWithResponse request
	GetApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiRecordingRuleGroupsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsOriginOrIdResponse, error)

	// PutApiRecordingRuleGroupsOriginOrIdWithBodyWithResponse request with any body
	PutApiRecordingRuleGroupsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiRecordingRuleGroupsOriginOrIdResponse, error)

	PutApiRecordingRuleGroupsOriginOrIdWithResponse(ctx context.Context, originOrId string, body PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiRecordingRuleGroupsOriginOrIdResponse, error)

	// GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse request
	GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse(ctx context.Context, originOrId string, version int64, params *GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams, reqEditors ...RequestEditorFn) (*GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse, error)

	// GetApiSamplingRulesWithResponse request
	GetApiSamplingRulesWithResponse(ctx context.Context, params *GetApiSamplingRulesParams, reqEditors ...RequestEditorFn) (*GetApiSamplingRulesResponse, error)

	// PostApiSamplingRulesWithBodyWithResponse request with any body
	PostApiSamplingRulesWithBodyWithResponse(ctx context.Context, params *PostApiSamplingRulesParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSamplingRulesResponse, error)

	PostApiSamplingRulesWithResponse(ctx context.Context, params *PostApiSamplingRulesParams, body PostApiSamplingRulesJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSamplingRulesResponse, error)

	// DeleteApiSamplingRulesOriginOrIdWithResponse request
	DeleteApiSamplingRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiSamplingRulesOriginOrIdResponse, error)

	// GetApiSamplingRulesOriginOrIdWithResponse request
	GetApiSamplingRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiSamplingRulesOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiSamplingRulesOriginOrIdResponse, error)

	// PutApiSamplingRulesOriginOrIdWithBodyWithResponse request with any body
	PutApiSamplingRulesOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiSamplingRulesOriginOrIdResponse, error)

	PutApiSamplingRulesOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiSamplingRulesOriginOrIdParams, body PutApiSamplingRulesOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiSamplingRulesOriginOrIdResponse, error)

	// PostApiSpansWithBodyWithResponse request with any body
	PostApiSpansWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSpansResponse, error)

	PostApiSpansWithResponse(ctx context.Context, body PostApiSpansJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSpansResponse, error)

	// PostApiSqlWithBodyWithResponse request with any body
	PostApiSqlWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSqlResponse, error)

	PostApiSqlWithResponse(ctx context.Context, body PostApiSqlJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSqlResponse, error)

	// GetApiSyntheticChecksWithResponse request
	GetApiSyntheticChecksWithResponse(ctx context.Context, params *GetApiSyntheticChecksParams, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksResponse, error)

	// PostApiSyntheticChecksWithBodyWithResponse request with any body
	PostApiSyntheticChecksWithBodyWithResponse(ctx context.Context, params *PostApiSyntheticChecksParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksResponse, error)

	PostApiSyntheticChecksWithResponse(ctx context.Context, params *PostApiSyntheticChecksParams, body PostApiSyntheticChecksJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksResponse, error)

	// GetApiSyntheticChecksLocationsWithResponse request
	GetApiSyntheticChecksLocationsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksLocationsResponse, error)

	// PostApiSyntheticChecksTestWithBodyWithResponse request with any body
	PostApiSyntheticChecksTestWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksTestResponse, error)

	PostApiSyntheticChecksTestWithResponse(ctx context.Context, body PostApiSyntheticChecksTestJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiSyntheticChecksTestResponse, error)

	// DeleteApiSyntheticChecksOriginOrIdWithResponse request
	DeleteApiSyntheticChecksOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiSyntheticChecksOriginOrIdResponse, error)

	// GetApiSyntheticChecksOriginOrIdWithResponse request
	GetApiSyntheticChecksOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiSyntheticChecksOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiSyntheticChecksOriginOrIdResponse, error)

	// PutApiSyntheticChecksOriginOrIdWithBodyWithResponse request with any body
	PutApiSyntheticChecksOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiSyntheticChecksOriginOrIdResponse, error)

	PutApiSyntheticChecksOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiSyntheticChecksOriginOrIdParams, body PutApiSyntheticChecksOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiSyntheticChecksOriginOrIdResponse, error)

	// GetApiTeamsWithResponse request
	GetApiTeamsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetApiTeamsResponse, error)

	// PostApiTeamsWithBodyWithResponse request with any body
	PostApiTeamsWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiTeamsResponse, error)

	PostApiTeamsWithResponse(ctx context.Context, body PostApiTeamsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiTeamsResponse, error)

	// DeleteApiTeamsOriginOrIdWithResponse request
	DeleteApiTeamsOriginOrIdWithResponse(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*DeleteApiTeamsOriginOrIdResponse, error)

	// GetApiTeamsOriginOrIdWithResponse request
	GetApiTeamsOriginOrIdWithResponse(ctx context.Context, originOrId string, reqEditors ...RequestEditorFn) (*GetApiTeamsOriginOrIdResponse, error)

	// PutApiTeamsOriginOrIdDisplayWithBodyWithResponse request with any body
	PutApiTeamsOriginOrIdDisplayWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiTeamsOriginOrIdDisplayResponse, error)

	PutApiTeamsOriginOrIdDisplayWithResponse(ctx context.Context, originOrId string, body PutApiTeamsOriginOrIdDisplayJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiTeamsOriginOrIdDisplayResponse, error)

	// PostApiTeamsOriginOrIdMembersWithBodyWithResponse request with any body
	PostApiTeamsOriginOrIdMembersWithBodyWithResponse(ctx context.Context, originOrId string, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiTeamsOriginOrIdMembersResponse, error)

	PostApiTeamsOriginOrIdMembersWithResponse(ctx context.Context, originOrId string, body PostApiTeamsOriginOrIdMembersJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiTeamsOriginOrIdMembersResponse, error)

	// DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse request
	DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse(ctx context.Context, originOrId string, memberID string, reqEditors ...RequestEditorFn) (*DeleteApiTeamsOriginOrIdMembersMemberIDResponse, error)

	// GetApiViewsWithResponse request
	GetApiViewsWithResponse(ctx context.Context, params *GetApiViewsParams, reqEditors ...RequestEditorFn) (*GetApiViewsResponse, error)

	// PostApiViewsWithBodyWithResponse request with any body
	PostApiViewsWithBodyWithResponse(ctx context.Context, params *PostApiViewsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostApiViewsResponse, error)

	PostApiViewsWithResponse(ctx context.Context, params *PostApiViewsParams, body PostApiViewsJSONRequestBody, reqEditors ...RequestEditorFn) (*PostApiViewsResponse, error)

	// DeleteApiViewsOriginOrIdWithResponse request
	DeleteApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *DeleteApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*DeleteApiViewsOriginOrIdResponse, error)

	// GetApiViewsOriginOrIdWithResponse request
	GetApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *GetApiViewsOriginOrIdParams, reqEditors ...RequestEditorFn) (*GetApiViewsOriginOrIdResponse, error)

	// PutApiViewsOriginOrIdWithBodyWithResponse request with any body
	PutApiViewsOriginOrIdWithBodyWithResponse(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PutApiViewsOriginOrIdResponse, error)

	PutApiViewsOriginOrIdWithResponse(ctx context.Context, originOrId string, params *PutApiViewsOriginOrIdParams, body PutApiViewsOriginOrIdJSONRequestBody, reqEditors ...RequestEditorFn) (*PutApiViewsOriginOrIdResponse, error)

	// GetOauthAuthorizeWithResponse request
	GetOauthAuthorizeWithResponse(ctx context.Context, params *GetOauthAuthorizeParams, reqEditors ...RequestEditorFn) (*GetOauthAuthorizeResponse, error)

	// PostOauthRegisterWithBodyWithResponse request with any body
	PostOauthRegisterWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthRegisterResponse, error)

	PostOauthRegisterWithResponse(ctx context.Context, body PostOauthRegisterJSONRequestBody, reqEditors ...RequestEditorFn) (*PostOauthRegisterResponse, error)

	// PostOauthRevokeWithBodyWithResponse request with any body
	PostOauthRevokeWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthRevokeResponse, error)

	PostOauthRevokeWithFormdataBodyWithResponse(ctx context.Context, body PostOauthRevokeFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostOauthRevokeResponse, error)

	// PostOauthTokenWithBodyWithResponse request with any body
	PostOauthTokenWithBodyWithResponse(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*PostOauthTokenResponse, error)

	PostOauthTokenWithFormdataBodyWithResponse(ctx context.Context, body PostOauthTokenFormdataRequestBody, reqEditors ...RequestEditorFn) (*PostOauthTokenResponse, error)
}

ClientWithResponsesInterface is the interface specification for the client with responses above.

type Cursor

type Cursor = string

Cursor The cursor to another set of results. The value of this field is opaque to the client and may be used as a parameter to the next request to get the another set of results. Cursors do not implement any ordering.

type CursorPagination

type CursorPagination struct {
	// Cursor The cursor to another set of results. The value of this field is opaque to the
	// client and may be used as a parameter to the next request to get the another set of results.
	// Cursors do not implement any ordering.
	Cursor *Cursor `json:"cursor,omitempty"`

	// Limit The maximum number of results to return. If not set, there is a default limit to the number of results returned.
	Limit *int64 `json:"limit,omitempty"`
}

CursorPagination Cursor pagination is a technique for paging through a result set using a cursor. It is similar to offset pagination except that the cursor is an opaque value that encodes the position within the result set. This allows for fetching the next page of results from the current position without having to skip over a potentially large number of rows.

It is also more resilient against late-arriving data which otherwise would cause issues with offset pagination. For example, if a row is inserted between two pages of results then the second page would contain a duplicate row and the third page would be missing.

type D0QLWarnings added in v1.6.0

type D0QLWarnings = []string

D0QLWarnings defines model for D0QLWarnings.

type DashboardAnnotations

type DashboardAnnotations struct {
	Dash0ComdeletedAt  *time.Time `json:"dash0.com/deleted-at,omitempty"`
	Dash0ComfolderPath *string    `json:"dash0.com/folder-path,omitempty"`
	Dash0Comsharing    *string    `json:"dash0.com/sharing,omitempty"`

	// Dash0Comsource The source that created the dashboard.
	Dash0Comsource *DashboardSource `json:"dash0.com/source,omitempty"`
}

DashboardAnnotations defines model for DashboardAnnotations.

type DashboardApiListItem

type DashboardApiListItem struct {
	Dataset     string   `json:"dataset"`
	Description *string  `json:"description,omitempty"`
	Id          string   `json:"id"`
	Name        *string  `json:"name,omitempty"`
	Origin      *string  `json:"origin,omitempty"`
	Tags        []string `json:"tags"`
}

DashboardApiListItem defines model for DashboardApiListItem.

type DashboardDefinition

type DashboardDefinition struct {
	Kind     DashboardDefinitionKind `json:"kind"`
	Metadata DashboardMetadata       `json:"metadata"`
	Spec     map[string]interface{}  `json:"spec"`
}

DashboardDefinition A dashboard definition that is compatible with Perses' dashboarding system.

func ConvertPersesDashboardToDashboard added in v1.6.0

func ConvertPersesDashboardToDashboard(perses *PersesDashboard) *DashboardDefinition

ConvertPersesDashboardToDashboard converts a PersesDashboard CRD into a Dash0 DashboardDefinition. It normalizes v1alpha1/v1alpha2 differences (the v1alpha2 CRD wraps the spec in a "config" key) and ensures a display name is set, falling back to metadata.name.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	perses := &dash0.PersesDashboard{
		APIVersion: "perses.dev/v1alpha1",
		Kind:       "PersesDashboard",
		Metadata:   dash0.PersesDashboardMetadata{Name: "my-perses-dashboard"},
		Spec: map[string]any{
			"display": map[string]any{"name": "Perses Dashboard"},
		},
	}
	dashboard := dash0.ConvertPersesDashboardToDashboard(perses)
	fmt.Println(dashboard.Metadata.Name)
}
Output:
Perses Dashboard

type DashboardDefinitionKind

type DashboardDefinitionKind string

DashboardDefinitionKind defines model for DashboardDefinition.Kind.

const (
	Dashboard DashboardDefinitionKind = "Dashboard"
)

Defines values for DashboardDefinitionKind.

type DashboardMetadata

type DashboardMetadata struct {
	Annotations     *DashboardAnnotations        `json:"annotations,omitempty"`
	CreatedAt       *time.Time                   `json:"createdAt,omitempty"`
	Dash0Extensions *DashboardMetadataExtensions `json:"dash0Extensions,omitempty"`
	Name            string                       `json:"name"`
	Project         *string                      `json:"project,omitempty"`
	UpdatedAt       *time.Time                   `json:"updatedAt,omitempty"`
	Version         *int64                       `json:"version,omitempty"`
}

DashboardMetadata defines model for DashboardMetadata.

type DashboardMetadataExtensions

type DashboardMetadataExtensions struct {
	// CreatedBy The member ID of the user who created this dashboard or dashboard version.
	CreatedBy *string `json:"createdBy,omitempty"`

	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset *Dataset `json:"dataset,omitempty"`

	// Id An immutable id field to support automatic dashboard creation based on Kubernetes CRDs. This
	// field essentially acts as an external ID for the dashboard. We support a way to upsert dashboards based
	// on this field.
	Id *string `json:"id,omitempty"`

	// Origin This field is deprecated and is replaced by id field.
	// Deprecated: this property has been marked as deprecated upstream, but no `x-deprecated-reason` was set
	Origin *string   `json:"origin,omitempty"`
	Tags   *[]string `json:"tags,omitempty"`
}

DashboardMetadataExtensions defines model for DashboardMetadataExtensions.

type DashboardSource added in v1.2.0

type DashboardSource string

DashboardSource The source that created the dashboard.

const (
	DashboardSourceApi       DashboardSource = "api"
	DashboardSourceOperator  DashboardSource = "operator"
	DashboardSourceTerraform DashboardSource = "terraform"
	DashboardSourceUi        DashboardSource = "ui"
)

Defines values for DashboardSource.

type Dataset

type Dataset = string

Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.

type DatasetRestriction added in v1.6.0

type DatasetRestriction string

DatasetRestriction defines model for DatasetRestriction.

const (
	Restricted   DatasetRestriction = "restricted"
	Unrestricted DatasetRestriction = "unrestricted"
)

Defines values for DatasetRestriction.

type DeleteApiAlertingCheckRulesOriginOrIdParams

type DeleteApiAlertingCheckRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiAlertingCheckRulesOriginOrIdParams defines parameters for DeleteApiAlertingCheckRulesOriginOrId.

type DeleteApiAlertingCheckRulesOriginOrIdResponse

type DeleteApiAlertingCheckRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiAlertingCheckRulesOriginOrIdResponse

func ParseDeleteApiAlertingCheckRulesOriginOrIdResponse(rsp *http.Response) (*DeleteApiAlertingCheckRulesOriginOrIdResponse, error)

ParseDeleteApiAlertingCheckRulesOriginOrIdResponse parses an HTTP response from a DeleteApiAlertingCheckRulesOriginOrIdWithResponse call

func (DeleteApiAlertingCheckRulesOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (DeleteApiAlertingCheckRulesOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type DeleteApiDashboardsOriginOrIdParams

type DeleteApiDashboardsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiDashboardsOriginOrIdParams defines parameters for DeleteApiDashboardsOriginOrId.

type DeleteApiDashboardsOriginOrIdResponse

type DeleteApiDashboardsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiDashboardsOriginOrIdResponse

func ParseDeleteApiDashboardsOriginOrIdResponse(rsp *http.Response) (*DeleteApiDashboardsOriginOrIdResponse, error)

ParseDeleteApiDashboardsOriginOrIdResponse parses an HTTP response from a DeleteApiDashboardsOriginOrIdWithResponse call

func (DeleteApiDashboardsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (DeleteApiDashboardsOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type DeleteApiMembersMemberIDResponse added in v1.4.0

type DeleteApiMembersMemberIDResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiMembersMemberIDResponse added in v1.4.0

func ParseDeleteApiMembersMemberIDResponse(rsp *http.Response) (*DeleteApiMembersMemberIDResponse, error)

ParseDeleteApiMembersMemberIDResponse parses an HTTP response from a DeleteApiMembersMemberIDWithResponse call

func (DeleteApiMembersMemberIDResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (DeleteApiMembersMemberIDResponse) StatusCode added in v1.4.0

func (r DeleteApiMembersMemberIDResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DeleteApiRecordingRuleGroupsOriginOrIdParams added in v1.6.0

type DeleteApiRecordingRuleGroupsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiRecordingRuleGroupsOriginOrIdParams defines parameters for DeleteApiRecordingRuleGroupsOriginOrId.

type DeleteApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

type DeleteApiRecordingRuleGroupsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

func ParseDeleteApiRecordingRuleGroupsOriginOrIdResponse(rsp *http.Response) (*DeleteApiRecordingRuleGroupsOriginOrIdResponse, error)

ParseDeleteApiRecordingRuleGroupsOriginOrIdResponse parses an HTTP response from a DeleteApiRecordingRuleGroupsOriginOrIdWithResponse call

func (DeleteApiRecordingRuleGroupsOriginOrIdResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (DeleteApiRecordingRuleGroupsOriginOrIdResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type DeleteApiSamplingRulesOriginOrIdParams added in v1.1.0

type DeleteApiSamplingRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiSamplingRulesOriginOrIdParams defines parameters for DeleteApiSamplingRulesOriginOrId.

type DeleteApiSamplingRulesOriginOrIdResponse added in v1.1.0

type DeleteApiSamplingRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON403      *ErrorResponse
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiSamplingRulesOriginOrIdResponse added in v1.1.0

func ParseDeleteApiSamplingRulesOriginOrIdResponse(rsp *http.Response) (*DeleteApiSamplingRulesOriginOrIdResponse, error)

ParseDeleteApiSamplingRulesOriginOrIdResponse parses an HTTP response from a DeleteApiSamplingRulesOriginOrIdWithResponse call

func (DeleteApiSamplingRulesOriginOrIdResponse) Status added in v1.1.0

Status returns HTTPResponse.Status

func (DeleteApiSamplingRulesOriginOrIdResponse) StatusCode added in v1.1.0

StatusCode returns HTTPResponse.StatusCode

type DeleteApiSyntheticChecksOriginOrIdParams

type DeleteApiSyntheticChecksOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiSyntheticChecksOriginOrIdParams defines parameters for DeleteApiSyntheticChecksOriginOrId.

type DeleteApiSyntheticChecksOriginOrIdResponse

type DeleteApiSyntheticChecksOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiSyntheticChecksOriginOrIdResponse

func ParseDeleteApiSyntheticChecksOriginOrIdResponse(rsp *http.Response) (*DeleteApiSyntheticChecksOriginOrIdResponse, error)

ParseDeleteApiSyntheticChecksOriginOrIdResponse parses an HTTP response from a DeleteApiSyntheticChecksOriginOrIdWithResponse call

func (DeleteApiSyntheticChecksOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (DeleteApiSyntheticChecksOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type DeleteApiTeamsOriginOrIdMembersMemberIDResponse added in v1.4.0

type DeleteApiTeamsOriginOrIdMembersMemberIDResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiTeamsOriginOrIdMembersMemberIDResponse added in v1.4.0

func ParseDeleteApiTeamsOriginOrIdMembersMemberIDResponse(rsp *http.Response) (*DeleteApiTeamsOriginOrIdMembersMemberIDResponse, error)

ParseDeleteApiTeamsOriginOrIdMembersMemberIDResponse parses an HTTP response from a DeleteApiTeamsOriginOrIdMembersMemberIDWithResponse call

func (DeleteApiTeamsOriginOrIdMembersMemberIDResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (DeleteApiTeamsOriginOrIdMembersMemberIDResponse) StatusCode added in v1.4.0

StatusCode returns HTTPResponse.StatusCode

type DeleteApiTeamsOriginOrIdResponse added in v1.4.0

type DeleteApiTeamsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiTeamsOriginOrIdResponse added in v1.4.0

func ParseDeleteApiTeamsOriginOrIdResponse(rsp *http.Response) (*DeleteApiTeamsOriginOrIdResponse, error)

ParseDeleteApiTeamsOriginOrIdResponse parses an HTTP response from a DeleteApiTeamsOriginOrIdWithResponse call

func (DeleteApiTeamsOriginOrIdResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (DeleteApiTeamsOriginOrIdResponse) StatusCode added in v1.4.0

func (r DeleteApiTeamsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type DeleteApiViewsOriginOrIdParams

type DeleteApiViewsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

DeleteApiViewsOriginOrIdParams defines parameters for DeleteApiViewsOriginOrId.

type DeleteApiViewsOriginOrIdResponse

type DeleteApiViewsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseDeleteApiViewsOriginOrIdResponse

func ParseDeleteApiViewsOriginOrIdResponse(rsp *http.Response) (*DeleteApiViewsOriginOrIdResponse, error)

ParseDeleteApiViewsOriginOrIdResponse parses an HTTP response from a DeleteApiViewsOriginOrIdWithResponse call

func (DeleteApiViewsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (DeleteApiViewsOriginOrIdResponse) StatusCode

func (r DeleteApiViewsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Duration

type Duration = string

Duration defines model for Duration.

type Error

type Error struct {
	Code    int     `json:"code"`
	Message string  `json:"message"`
	TraceId *string `json:"traceId,omitempty"`
}

Error defines model for Error.

type ErrorAssertion

type ErrorAssertion struct {
	Kind ErrorAssertionKind `json:"kind"`
	Spec ErrorAssertionSpec `json:"spec"`
}

ErrorAssertion defines model for ErrorAssertion.

type ErrorAssertionKind

type ErrorAssertionKind string

ErrorAssertionKind defines model for ErrorAssertion.Kind.

const (
	ErrorAssertionKindError ErrorAssertionKind = "error"
)

Defines values for ErrorAssertionKind.

type ErrorAssertionSpec

type ErrorAssertionSpec struct {
	Value SyntheticHttpErrorType `json:"value"`
}

ErrorAssertionSpec defines model for ErrorAssertionSpec.

type ErrorResponse

type ErrorResponse struct {
	Error Error `json:"error"`
}

ErrorResponse defines model for ErrorResponse.

type ExecuteSqlRequest added in v1.6.0

type ExecuteSqlRequest struct {
	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset *Dataset `json:"dataset,omitempty"`
	Query   string   `json:"query"`

	// TimeRange A range of time between two time references.
	TimeRange TimeReferenceRange `json:"timeRange"`
}

ExecuteSqlRequest defines model for ExecuteSqlRequest.

type ExecuteSqlResponse added in v1.6.0

type ExecuteSqlResponse struct {
	Error *string `json:"error,omitempty"`

	// ExecutionTime A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	ExecutionTime FixedTime    `json:"executionTime"`
	Progress      *Progress    `json:"progress,omitempty"`
	ResultRows    *ResultRows  `json:"resultRows,omitempty"`
	TimeRange     TimeRange    `json:"timeRange"`
	Warnings      D0QLWarnings `json:"warnings"`
}

ExecuteSqlResponse defines model for ExecuteSqlResponse.

type FailedHttpCheckAssertion added in v1.4.0

type FailedHttpCheckAssertion struct {
	// ActualValue The actual value that was received in the response
	ActualValue *string            `json:"actualValue,omitempty"`
	Assertion   HttpCheckAssertion `json:"assertion"`

	// Explanation A human-readable message explaining why the assertion failed
	Explanation string `json:"explanation"`
}

FailedHttpCheckAssertion Information about a failed HTTP check assertion

type FilterCriteria

type FilterCriteria = []AttributeFilter

FilterCriteria defines model for FilterCriteria.

type FixedTime

type FixedTime = time.Time

FixedTime A fixed point in time represented as an RFC 3339 date-time string.

**Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)

**Examples**: - `2024-01-15T14:30:00Z` - `2024-01-15T14:30:00+08:00`

type FixedTimeUnix

type FixedTimeUnix = string

FixedTimeUnix The time corresponding to the given unix time in seconds and nanoseconds (as decimal places) since January 1, 1970 UTC.

type GetApiAlertingCheckRulesOriginOrIdParams

type GetApiAlertingCheckRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiAlertingCheckRulesOriginOrIdParams defines parameters for GetApiAlertingCheckRulesOriginOrId.

type GetApiAlertingCheckRulesOriginOrIdResponse

type GetApiAlertingCheckRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *PrometheusAlertRule
	JSONDefault  *ErrorResponse
}

func ParseGetApiAlertingCheckRulesOriginOrIdResponse

func ParseGetApiAlertingCheckRulesOriginOrIdResponse(rsp *http.Response) (*GetApiAlertingCheckRulesOriginOrIdResponse, error)

ParseGetApiAlertingCheckRulesOriginOrIdResponse parses an HTTP response from a GetApiAlertingCheckRulesOriginOrIdWithResponse call

func (GetApiAlertingCheckRulesOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (GetApiAlertingCheckRulesOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type GetApiAlertingCheckRulesParams

type GetApiAlertingCheckRulesParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`

	// IdPrefix If provided, only check rules for which the origin starts with the given string are returned. (deprecated)
	//
	// The `originPrefix` query parameter takes precedence over this parameter if both are provided.
	IdPrefix *string `form:"idPrefix,omitempty" json:"idPrefix,omitempty"`

	// OriginPrefix If provided, only check rules for which the origin starts with the given string are returned.
	OriginPrefix *string `form:"originPrefix,omitempty" json:"originPrefix,omitempty"`
}

GetApiAlertingCheckRulesParams defines parameters for GetApiAlertingCheckRules.

type GetApiAlertingCheckRulesResponse

type GetApiAlertingCheckRulesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]PrometheusAlertRuleApiListItem
	JSONDefault  *ErrorResponse
}

func ParseGetApiAlertingCheckRulesResponse

func ParseGetApiAlertingCheckRulesResponse(rsp *http.Response) (*GetApiAlertingCheckRulesResponse, error)

ParseGetApiAlertingCheckRulesResponse parses an HTTP response from a GetApiAlertingCheckRulesWithResponse call

func (GetApiAlertingCheckRulesResponse) Status

Status returns HTTPResponse.Status

func (GetApiAlertingCheckRulesResponse) StatusCode

func (r GetApiAlertingCheckRulesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiDashboardsOriginOrIdParams

type GetApiDashboardsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiDashboardsOriginOrIdParams defines parameters for GetApiDashboardsOriginOrId.

type GetApiDashboardsOriginOrIdResponse

type GetApiDashboardsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *DashboardDefinition
	JSONDefault  *ErrorResponse
}

func ParseGetApiDashboardsOriginOrIdResponse

func ParseGetApiDashboardsOriginOrIdResponse(rsp *http.Response) (*GetApiDashboardsOriginOrIdResponse, error)

ParseGetApiDashboardsOriginOrIdResponse parses an HTTP response from a GetApiDashboardsOriginOrIdWithResponse call

func (GetApiDashboardsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (GetApiDashboardsOriginOrIdResponse) StatusCode

func (r GetApiDashboardsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiDashboardsParams

type GetApiDashboardsParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiDashboardsParams defines parameters for GetApiDashboards.

type GetApiDashboardsResponse

type GetApiDashboardsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]DashboardApiListItem
	JSONDefault  *ErrorResponse
}

func ParseGetApiDashboardsResponse

func ParseGetApiDashboardsResponse(rsp *http.Response) (*GetApiDashboardsResponse, error)

ParseGetApiDashboardsResponse parses an HTTP response from a GetApiDashboardsWithResponse call

func (GetApiDashboardsResponse) Status

func (r GetApiDashboardsResponse) Status() string

Status returns HTTPResponse.Status

func (GetApiDashboardsResponse) StatusCode

func (r GetApiDashboardsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiMembersResponse added in v1.4.0

type GetApiMembersResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]MemberDefinition
	JSONDefault  *ErrorResponse
}

func ParseGetApiMembersResponse added in v1.4.0

func ParseGetApiMembersResponse(rsp *http.Response) (*GetApiMembersResponse, error)

ParseGetApiMembersResponse parses an HTTP response from a GetApiMembersWithResponse call

func (GetApiMembersResponse) Status added in v1.4.0

func (r GetApiMembersResponse) Status() string

Status returns HTTPResponse.Status

func (GetApiMembersResponse) StatusCode added in v1.4.0

func (r GetApiMembersResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiRecordingRuleGroupsOriginOrIdParams added in v1.6.0

type GetApiRecordingRuleGroupsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiRecordingRuleGroupsOriginOrIdParams defines parameters for GetApiRecordingRuleGroupsOriginOrId.

type GetApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

type GetApiRecordingRuleGroupsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *RecordingRuleGroupResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

func ParseGetApiRecordingRuleGroupsOriginOrIdResponse(rsp *http.Response) (*GetApiRecordingRuleGroupsOriginOrIdResponse, error)

ParseGetApiRecordingRuleGroupsOriginOrIdResponse parses an HTTP response from a GetApiRecordingRuleGroupsOriginOrIdWithResponse call

func (GetApiRecordingRuleGroupsOriginOrIdResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetApiRecordingRuleGroupsOriginOrIdResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams added in v1.6.0

type GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiRecordingRuleGroupsOriginOrIdVersionsVersionParams defines parameters for GetApiRecordingRuleGroupsOriginOrIdVersionsVersion.

type GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse added in v1.6.0

type GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *RecordingRuleGroupResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse added in v1.6.0

func ParseGetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse(rsp *http.Response) (*GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse, error)

ParseGetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse parses an HTTP response from a GetApiRecordingRuleGroupsOriginOrIdVersionsVersionWithResponse call

func (GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetApiRecordingRuleGroupsOriginOrIdVersionsVersionResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type GetApiRecordingRuleGroupsParams added in v1.6.0

type GetApiRecordingRuleGroupsParams struct {
	// Dataset Filter by dataset.
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`

	// OriginPrefix Filter by origin prefix.
	OriginPrefix *string `form:"originPrefix,omitempty" json:"originPrefix,omitempty"`
}

GetApiRecordingRuleGroupsParams defines parameters for GetApiRecordingRuleGroups.

type GetApiRecordingRuleGroupsResponse added in v1.6.0

type GetApiRecordingRuleGroupsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *RecordingRuleGroupListResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiRecordingRuleGroupsResponse added in v1.6.0

func ParseGetApiRecordingRuleGroupsResponse(rsp *http.Response) (*GetApiRecordingRuleGroupsResponse, error)

ParseGetApiRecordingRuleGroupsResponse parses an HTTP response from a GetApiRecordingRuleGroupsWithResponse call

func (GetApiRecordingRuleGroupsResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetApiRecordingRuleGroupsResponse) StatusCode added in v1.6.0

func (r GetApiRecordingRuleGroupsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiSamplingRulesOriginOrIdParams added in v1.1.0

type GetApiSamplingRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiSamplingRulesOriginOrIdParams defines parameters for GetApiSamplingRulesOriginOrId.

type GetApiSamplingRulesOriginOrIdResponse added in v1.1.0

type GetApiSamplingRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SamplingRuleResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiSamplingRulesOriginOrIdResponse added in v1.1.0

func ParseGetApiSamplingRulesOriginOrIdResponse(rsp *http.Response) (*GetApiSamplingRulesOriginOrIdResponse, error)

ParseGetApiSamplingRulesOriginOrIdResponse parses an HTTP response from a GetApiSamplingRulesOriginOrIdWithResponse call

func (GetApiSamplingRulesOriginOrIdResponse) Status added in v1.1.0

Status returns HTTPResponse.Status

func (GetApiSamplingRulesOriginOrIdResponse) StatusCode added in v1.1.0

StatusCode returns HTTPResponse.StatusCode

type GetApiSamplingRulesParams added in v1.1.0

type GetApiSamplingRulesParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiSamplingRulesParams defines parameters for GetApiSamplingRules.

type GetApiSamplingRulesResponse added in v1.1.0

type GetApiSamplingRulesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *GetSamplingRulesResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiSamplingRulesResponse added in v1.1.0

func ParseGetApiSamplingRulesResponse(rsp *http.Response) (*GetApiSamplingRulesResponse, error)

ParseGetApiSamplingRulesResponse parses an HTTP response from a GetApiSamplingRulesWithResponse call

func (GetApiSamplingRulesResponse) Status added in v1.1.0

Status returns HTTPResponse.Status

func (GetApiSamplingRulesResponse) StatusCode added in v1.1.0

func (r GetApiSamplingRulesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiSyntheticChecksLocationsResponse added in v1.6.0

type GetApiSyntheticChecksLocationsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]SyntheticCheckLocation
	JSONDefault  *ErrorResponse
}

func ParseGetApiSyntheticChecksLocationsResponse added in v1.6.0

func ParseGetApiSyntheticChecksLocationsResponse(rsp *http.Response) (*GetApiSyntheticChecksLocationsResponse, error)

ParseGetApiSyntheticChecksLocationsResponse parses an HTTP response from a GetApiSyntheticChecksLocationsWithResponse call

func (GetApiSyntheticChecksLocationsResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetApiSyntheticChecksLocationsResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type GetApiSyntheticChecksOriginOrIdParams

type GetApiSyntheticChecksOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiSyntheticChecksOriginOrIdParams defines parameters for GetApiSyntheticChecksOriginOrId.

type GetApiSyntheticChecksOriginOrIdResponse

type GetApiSyntheticChecksOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SyntheticCheckDefinition
	JSONDefault  *ErrorResponse
}

func ParseGetApiSyntheticChecksOriginOrIdResponse

func ParseGetApiSyntheticChecksOriginOrIdResponse(rsp *http.Response) (*GetApiSyntheticChecksOriginOrIdResponse, error)

ParseGetApiSyntheticChecksOriginOrIdResponse parses an HTTP response from a GetApiSyntheticChecksOriginOrIdWithResponse call

func (GetApiSyntheticChecksOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (GetApiSyntheticChecksOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type GetApiSyntheticChecksParams

type GetApiSyntheticChecksParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiSyntheticChecksParams defines parameters for GetApiSyntheticChecks.

type GetApiSyntheticChecksResponse

type GetApiSyntheticChecksResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]SyntheticChecksApiListItem
	JSONDefault  *ErrorResponse
}

func ParseGetApiSyntheticChecksResponse

func ParseGetApiSyntheticChecksResponse(rsp *http.Response) (*GetApiSyntheticChecksResponse, error)

ParseGetApiSyntheticChecksResponse parses an HTTP response from a GetApiSyntheticChecksWithResponse call

func (GetApiSyntheticChecksResponse) Status

Status returns HTTPResponse.Status

func (GetApiSyntheticChecksResponse) StatusCode

func (r GetApiSyntheticChecksResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiTeamsOriginOrIdResponse added in v1.4.0

type GetApiTeamsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *GetTeamResponse
	JSONDefault  *ErrorResponse
}

func ParseGetApiTeamsOriginOrIdResponse added in v1.4.0

func ParseGetApiTeamsOriginOrIdResponse(rsp *http.Response) (*GetApiTeamsOriginOrIdResponse, error)

ParseGetApiTeamsOriginOrIdResponse parses an HTTP response from a GetApiTeamsOriginOrIdWithResponse call

func (GetApiTeamsOriginOrIdResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (GetApiTeamsOriginOrIdResponse) StatusCode added in v1.4.0

func (r GetApiTeamsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiTeamsResponse added in v1.4.0

type GetApiTeamsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]TeamsListItem
	JSONDefault  *ErrorResponse
}

func ParseGetApiTeamsResponse added in v1.4.0

func ParseGetApiTeamsResponse(rsp *http.Response) (*GetApiTeamsResponse, error)

ParseGetApiTeamsResponse parses an HTTP response from a GetApiTeamsWithResponse call

func (GetApiTeamsResponse) Status added in v1.4.0

func (r GetApiTeamsResponse) Status() string

Status returns HTTPResponse.Status

func (GetApiTeamsResponse) StatusCode added in v1.4.0

func (r GetApiTeamsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiViewsOriginOrIdParams

type GetApiViewsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiViewsOriginOrIdParams defines parameters for GetApiViewsOriginOrId.

type GetApiViewsOriginOrIdResponse

type GetApiViewsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *ViewDefinition
	JSONDefault  *ErrorResponse
}

func ParseGetApiViewsOriginOrIdResponse

func ParseGetApiViewsOriginOrIdResponse(rsp *http.Response) (*GetApiViewsOriginOrIdResponse, error)

ParseGetApiViewsOriginOrIdResponse parses an HTTP response from a GetApiViewsOriginOrIdWithResponse call

func (GetApiViewsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (GetApiViewsOriginOrIdResponse) StatusCode

func (r GetApiViewsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetApiViewsParams

type GetApiViewsParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

GetApiViewsParams defines parameters for GetApiViews.

type GetApiViewsResponse

type GetApiViewsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]ViewApiListItem
	JSONDefault  *ErrorResponse
}

func ParseGetApiViewsResponse

func ParseGetApiViewsResponse(rsp *http.Response) (*GetApiViewsResponse, error)

ParseGetApiViewsResponse parses an HTTP response from a GetApiViewsWithResponse call

func (GetApiViewsResponse) Status

func (r GetApiViewsResponse) Status() string

Status returns HTTPResponse.Status

func (GetApiViewsResponse) StatusCode

func (r GetApiViewsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetLogRecordsRequest

type GetLogRecordsRequest struct {
	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset *Dataset        `json:"dataset,omitempty"`
	Filter  *FilterCriteria `json:"filter,omitempty"`

	// Ordering Any supported attribute keys to order by.
	Ordering *OrderingCriteria `json:"ordering,omitempty"`

	// Pagination Cursor pagination is a technique for paging through a result set using a cursor. It is
	// similar to offset pagination except that the cursor is an opaque value that encodes the
	// position within the result set. This allows for fetching the next page of results from
	// the current position without having to skip over a potentially large number of rows.
	//
	// It is also more resilient against late-arriving data which otherwise would cause issues
	// with offset pagination. For example, if a row is inserted between two pages of results
	// then the second page would contain a duplicate row and the third page would be missing.
	Pagination *CursorPagination `json:"pagination,omitempty"`
	Sampling   *Sampling         `json:"sampling,omitempty"`

	// TimeRange A range of time between two time references.
	TimeRange TimeReferenceRange `json:"timeRange"`
}

GetLogRecordsRequest defines model for GetLogRecordsRequest.

type GetLogRecordsResponse

type GetLogRecordsResponse struct {
	Cursors *NextCursors `json:"cursors,omitempty"`

	// ExecutionTime A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	ExecutionTime *FixedTime `json:"executionTime,omitempty"`

	// ResourceLogs There is one `ResourceLogs` per resource. This is aligned to the data most OTLP batching algorithms would
	// produce, where there is one `ResourceLogs` per resource. This is done to aid compatibility with existing
	// OTLP consumers.
	//
	// `ResourceLogs` are **NOT** sorted. There is no guarantee that `ResourceLogs` are sorted or that
	// `LogRecord`s within them are sorted. However, it is guaranteed that all data is sorted across paged
	// requests.
	//
	// Clients are advised to implement sorting within a page descending by the `LogRecord`'s `timeUnixNano`,
	// `observedTimeUnixNano` and then `id`.
	ResourceLogs []ResourceLogs `json:"resourceLogs"`
	TimeRange    *TimeRange     `json:"timeRange,omitempty"`
}

GetLogRecordsResponse Response for the `GetLogRecords` API. The response contains the log records that match the request.

This API deliberately reuses the full OTLP JSON format for logs. This is done to aid compatibility with existing OTLP consumers.

type GetOauthAuthorizeParams added in v1.6.0

type GetOauthAuthorizeParams struct {
	// ResponseType Must be "code" for the authorization code flow.
	ResponseType string `form:"response_type" json:"response_type"`

	// ClientId The client identifier obtained during registration.
	ClientId string `form:"client_id" json:"client_id"`

	// RedirectUri Must match one of the client's registered redirect URIs.
	RedirectUri string `form:"redirect_uri" json:"redirect_uri"`

	// Scope Space-separated list of requested scopes.
	Scope *string `form:"scope,omitempty" json:"scope,omitempty"`

	// State Opaque value for CSRF protection, returned unchanged in the redirect.
	State *string `form:"state,omitempty" json:"state,omitempty"`

	// CodeChallenge PKCE code challenge (RFC 7636).
	CodeChallenge string `form:"code_challenge" json:"code_challenge"`

	// CodeChallengeMethod Must be "S256".
	CodeChallengeMethod string `form:"code_challenge_method" json:"code_challenge_method"`

	// Prompt Space-separated list of prompt directives. Supported value: "consent".
	Prompt *string `form:"prompt,omitempty" json:"prompt,omitempty"`
}

GetOauthAuthorizeParams defines parameters for GetOauthAuthorize.

type GetOauthAuthorizeResponse added in v1.6.0

type GetOauthAuthorizeResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParseGetOauthAuthorizeResponse added in v1.6.0

func ParseGetOauthAuthorizeResponse(rsp *http.Response) (*GetOauthAuthorizeResponse, error)

ParseGetOauthAuthorizeResponse parses an HTTP response from a GetOauthAuthorizeWithResponse call

func (GetOauthAuthorizeResponse) Status added in v1.6.0

func (r GetOauthAuthorizeResponse) Status() string

Status returns HTTPResponse.Status

func (GetOauthAuthorizeResponse) StatusCode added in v1.6.0

func (r GetOauthAuthorizeResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GetSamplingRulesResponse added in v1.1.0

type GetSamplingRulesResponse struct {
	SamplingRules []SamplingDefinition `json:"samplingRules"`
}

GetSamplingRulesResponse defines model for GetSamplingRulesResponse.

type GetSpansRequest

type GetSpansRequest struct {
	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset *Dataset        `json:"dataset,omitempty"`
	Filter  *FilterCriteria `json:"filter,omitempty"`

	// Ordering Any supported attribute keys to order by.
	Ordering *OrderingCriteria `json:"ordering,omitempty"`

	// Pagination Cursor pagination is a technique for paging through a result set using a cursor. It is
	// similar to offset pagination except that the cursor is an opaque value that encodes the
	// position within the result set. This allows for fetching the next page of results from
	// the current position without having to skip over a potentially large number of rows.
	//
	// It is also more resilient against late-arriving data which otherwise would cause issues
	// with offset pagination. For example, if a row is inserted between two pages of results
	// then the second page would contain a duplicate row and the third page would be missing.
	Pagination *CursorPagination `json:"pagination,omitempty"`
	Sampling   *Sampling         `json:"sampling,omitempty"`

	// TimeRange A range of time between two time references.
	TimeRange TimeReferenceRange `json:"timeRange"`
}

GetSpansRequest defines model for GetSpansRequest.

type GetSpansResponse

type GetSpansResponse struct {
	Cursors *NextCursors `json:"cursors,omitempty"`

	// ExecutionTime A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	ExecutionTime *FixedTime `json:"executionTime,omitempty"`

	// ResourceSpans There is one `ResourceSpan` per resource. This is aligned to the data most OTLP batching algorithms would
	// produce, where there is one `ResourceSpan` per resource. This is done to aid compatibility with existing
	// OTLP consumers.
	//
	// `Spans` nested in `ResourceSpans` are **ONLY** sorted if an explicit ordering has been defined. However,
	// it is guaranteed that all data is sorted across paged requests.
	ResourceSpans []ResourceSpans `json:"resourceSpans"`
	TimeRange     *TimeRange      `json:"timeRange,omitempty"`
}

GetSpansResponse Response for the `GetSpans` API. The response contains the spans that match the request.

This API deliberately reuses the full OTLP JSON format for spans. This is done to aid compatibility with existing OTLP consumers.

type GetTeamResponse added in v1.4.0

type GetTeamResponse struct {
	CheckRules      []AccessibleAsset  `json:"checkRules"`
	Dashboards      []AccessibleAsset  `json:"dashboards"`
	Datasets        []AccessibleAsset  `json:"datasets"`
	Members         []MemberDefinition `json:"members"`
	SyntheticChecks []AccessibleAsset  `json:"syntheticChecks"`
	Team            TeamDefinition     `json:"team"`
	Views           []AccessibleAsset  `json:"views"`
}

GetTeamResponse defines model for GetTeamResponse.

type GetWellKnownOauthAuthorizationServerResponse added in v1.6.0

type GetWellKnownOauthAuthorizationServerResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *OAuthAuthorizationServerMetadata
	JSONDefault  *ErrorResponse
}

func ParseGetWellKnownOauthAuthorizationServerResponse added in v1.6.0

func ParseGetWellKnownOauthAuthorizationServerResponse(rsp *http.Response) (*GetWellKnownOauthAuthorizationServerResponse, error)

ParseGetWellKnownOauthAuthorizationServerResponse parses an HTTP response from a GetWellKnownOauthAuthorizationServerWithResponse call

func (GetWellKnownOauthAuthorizationServerResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetWellKnownOauthAuthorizationServerResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type GetWellKnownOauthProtectedResourceResponse added in v1.6.0

type GetWellKnownOauthProtectedResourceResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *OAuthProtectedResourceMetadata
	JSONDefault  *ErrorResponse
}

func ParseGetWellKnownOauthProtectedResourceResponse added in v1.6.0

func ParseGetWellKnownOauthProtectedResourceResponse(rsp *http.Response) (*GetWellKnownOauthProtectedResourceResponse, error)

ParseGetWellKnownOauthProtectedResourceResponse parses an HTTP response from a GetWellKnownOauthProtectedResourceWithResponse call

func (GetWellKnownOauthProtectedResourceResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (GetWellKnownOauthProtectedResourceResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type Gradient added in v1.4.0

type Gradient struct {
	From string `json:"from"`
	To   string `json:"to"`
}

Gradient A color gradient from one color to another.

type HttpBasicAuthentication

type HttpBasicAuthentication struct {
	Password string `json:"password"`
	Username string `json:"username"`
}

HttpBasicAuthentication defines model for HttpBasicAuthentication.

type HttpCheckAssertion

type HttpCheckAssertion struct {
	// contains filtered or unexported fields
}

HttpCheckAssertion defines model for HttpCheckAssertion.

func (HttpCheckAssertion) AsErrorAssertion

func (t HttpCheckAssertion) AsErrorAssertion() (ErrorAssertion, error)

AsErrorAssertion returns the union data inside the HttpCheckAssertion as a ErrorAssertion

func (HttpCheckAssertion) AsHttpResponseHeaderAssertion

func (t HttpCheckAssertion) AsHttpResponseHeaderAssertion() (HttpResponseHeaderAssertion, error)

AsHttpResponseHeaderAssertion returns the union data inside the HttpCheckAssertion as a HttpResponseHeaderAssertion

func (HttpCheckAssertion) AsHttpResponseJsonBodyAssertion

func (t HttpCheckAssertion) AsHttpResponseJsonBodyAssertion() (HttpResponseJsonBodyAssertion, error)

AsHttpResponseJsonBodyAssertion returns the union data inside the HttpCheckAssertion as a HttpResponseJsonBodyAssertion

func (HttpCheckAssertion) AsHttpResponseStatusCodeAssertion

func (t HttpCheckAssertion) AsHttpResponseStatusCodeAssertion() (HttpResponseStatusCodeAssertion, error)

AsHttpResponseStatusCodeAssertion returns the union data inside the HttpCheckAssertion as a HttpResponseStatusCodeAssertion

func (HttpCheckAssertion) AsHttpResponseTextBodyAssertion

func (t HttpCheckAssertion) AsHttpResponseTextBodyAssertion() (HttpResponseTextBodyAssertion, error)

AsHttpResponseTextBodyAssertion returns the union data inside the HttpCheckAssertion as a HttpResponseTextBodyAssertion

func (HttpCheckAssertion) AsSslCertificateAssertion

func (t HttpCheckAssertion) AsSslCertificateAssertion() (SslCertificateAssertion, error)

AsSslCertificateAssertion returns the union data inside the HttpCheckAssertion as a SslCertificateAssertion

func (HttpCheckAssertion) AsTimingAssertion

func (t HttpCheckAssertion) AsTimingAssertion() (TimingAssertion, error)

AsTimingAssertion returns the union data inside the HttpCheckAssertion as a TimingAssertion

func (*HttpCheckAssertion) FromErrorAssertion

func (t *HttpCheckAssertion) FromErrorAssertion(v ErrorAssertion) error

FromErrorAssertion overwrites any union data inside the HttpCheckAssertion as the provided ErrorAssertion

func (*HttpCheckAssertion) FromHttpResponseHeaderAssertion

func (t *HttpCheckAssertion) FromHttpResponseHeaderAssertion(v HttpResponseHeaderAssertion) error

FromHttpResponseHeaderAssertion overwrites any union data inside the HttpCheckAssertion as the provided HttpResponseHeaderAssertion

func (*HttpCheckAssertion) FromHttpResponseJsonBodyAssertion

func (t *HttpCheckAssertion) FromHttpResponseJsonBodyAssertion(v HttpResponseJsonBodyAssertion) error

FromHttpResponseJsonBodyAssertion overwrites any union data inside the HttpCheckAssertion as the provided HttpResponseJsonBodyAssertion

func (*HttpCheckAssertion) FromHttpResponseStatusCodeAssertion

func (t *HttpCheckAssertion) FromHttpResponseStatusCodeAssertion(v HttpResponseStatusCodeAssertion) error

FromHttpResponseStatusCodeAssertion overwrites any union data inside the HttpCheckAssertion as the provided HttpResponseStatusCodeAssertion

func (*HttpCheckAssertion) FromHttpResponseTextBodyAssertion

func (t *HttpCheckAssertion) FromHttpResponseTextBodyAssertion(v HttpResponseTextBodyAssertion) error

FromHttpResponseTextBodyAssertion overwrites any union data inside the HttpCheckAssertion as the provided HttpResponseTextBodyAssertion

func (*HttpCheckAssertion) FromSslCertificateAssertion

func (t *HttpCheckAssertion) FromSslCertificateAssertion(v SslCertificateAssertion) error

FromSslCertificateAssertion overwrites any union data inside the HttpCheckAssertion as the provided SslCertificateAssertion

func (*HttpCheckAssertion) FromTimingAssertion

func (t *HttpCheckAssertion) FromTimingAssertion(v TimingAssertion) error

FromTimingAssertion overwrites any union data inside the HttpCheckAssertion as the provided TimingAssertion

func (HttpCheckAssertion) MarshalJSON

func (t HttpCheckAssertion) MarshalJSON() ([]byte, error)

func (*HttpCheckAssertion) MergeErrorAssertion

func (t *HttpCheckAssertion) MergeErrorAssertion(v ErrorAssertion) error

MergeErrorAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided ErrorAssertion

func (*HttpCheckAssertion) MergeHttpResponseHeaderAssertion

func (t *HttpCheckAssertion) MergeHttpResponseHeaderAssertion(v HttpResponseHeaderAssertion) error

MergeHttpResponseHeaderAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided HttpResponseHeaderAssertion

func (*HttpCheckAssertion) MergeHttpResponseJsonBodyAssertion

func (t *HttpCheckAssertion) MergeHttpResponseJsonBodyAssertion(v HttpResponseJsonBodyAssertion) error

MergeHttpResponseJsonBodyAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided HttpResponseJsonBodyAssertion

func (*HttpCheckAssertion) MergeHttpResponseStatusCodeAssertion

func (t *HttpCheckAssertion) MergeHttpResponseStatusCodeAssertion(v HttpResponseStatusCodeAssertion) error

MergeHttpResponseStatusCodeAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided HttpResponseStatusCodeAssertion

func (*HttpCheckAssertion) MergeHttpResponseTextBodyAssertion

func (t *HttpCheckAssertion) MergeHttpResponseTextBodyAssertion(v HttpResponseTextBodyAssertion) error

MergeHttpResponseTextBodyAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided HttpResponseTextBodyAssertion

func (*HttpCheckAssertion) MergeSslCertificateAssertion

func (t *HttpCheckAssertion) MergeSslCertificateAssertion(v SslCertificateAssertion) error

MergeSslCertificateAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided SslCertificateAssertion

func (*HttpCheckAssertion) MergeTimingAssertion

func (t *HttpCheckAssertion) MergeTimingAssertion(v TimingAssertion) error

MergeTimingAssertion performs a merge with any union data inside the HttpCheckAssertion, using the provided TimingAssertion

func (*HttpCheckAssertion) UnmarshalJSON

func (t *HttpCheckAssertion) UnmarshalJSON(b []byte) error

type HttpCheckAssertions

type HttpCheckAssertions = []HttpCheckAssertion

HttpCheckAssertions defines model for HttpCheckAssertions.

type HttpHeaders

type HttpHeaders = []NameValuePair

HttpHeaders defines model for HttpHeaders.

type HttpQueryParameters

type HttpQueryParameters = []NameValuePair

HttpQueryParameters defines model for HttpQueryParameters.

type HttpRedirects

type HttpRedirects string

HttpRedirects defines model for HttpRedirects.

const (
	HttpRedirectsDisabled HttpRedirects = "disabled"
	HttpRedirectsFollow   HttpRedirects = "follow"
)

Defines values for HttpRedirects.

type HttpRequestBody

type HttpRequestBody struct {
	Kind HttpRequestBodyKind `json:"kind"`
	Spec struct {
		Content string `json:"content"`
	} `json:"spec"`
}

HttpRequestBody defines model for HttpRequestBody.

type HttpRequestBodyKind

type HttpRequestBodyKind string

HttpRequestBodyKind defines model for HttpRequestBodyKind.

const (
	Form    HttpRequestBodyKind = "form"
	Graphql HttpRequestBodyKind = "graphql"
	Json    HttpRequestBodyKind = "json"
	Raw     HttpRequestBodyKind = "raw"
)

Defines values for HttpRequestBodyKind.

type HttpRequestDoer

type HttpRequestDoer interface {
	Do(req *http.Request) (*http.Response, error)
}

Doer performs HTTP requests.

The standard http.Client implements this interface.

type HttpRequestMethod

type HttpRequestMethod string

HttpRequestMethod defines model for HttpRequestMethod.

const (
	Delete HttpRequestMethod = "delete"
	Get    HttpRequestMethod = "get"
	Head   HttpRequestMethod = "head"
	Patch  HttpRequestMethod = "patch"
	Post   HttpRequestMethod = "post"
	Put    HttpRequestMethod = "put"
)

Defines values for HttpRequestMethod.

type HttpRequestSpec

type HttpRequestSpec struct {
	BasicAuthentication *HttpBasicAuthentication `json:"basicAuthentication,omitempty"`
	Body                *HttpRequestBody         `json:"body,omitempty"`
	Headers             HttpHeaders              `json:"headers"`
	Method              HttpRequestMethod        `json:"method"`
	QueryParameters     HttpQueryParameters      `json:"queryParameters"`
	Redirects           HttpRedirects            `json:"redirects"`
	Tls                 TlsSettings              `json:"tls"`
	Tracing             TracingSettings          `json:"tracing"`
	Url                 string                   `json:"url"`
}

HttpRequestSpec defines model for HttpRequestSpec.

type HttpResponseHeaderAssertion

type HttpResponseHeaderAssertion struct {
	Kind HttpResponseHeaderAssertionKind `json:"kind"`
	Spec HttpResponseHeaderAssertionSpec `json:"spec"`
}

HttpResponseHeaderAssertion defines model for HttpResponseHeaderAssertion.

type HttpResponseHeaderAssertionKind

type HttpResponseHeaderAssertionKind string

HttpResponseHeaderAssertionKind defines model for HttpResponseHeaderAssertion.Kind.

const (
	ResponseHeader HttpResponseHeaderAssertionKind = "response_header"
)

Defines values for HttpResponseHeaderAssertionKind.

type HttpResponseHeaderAssertionSpec

type HttpResponseHeaderAssertionSpec struct {
	Key      string                  `json:"key"`
	Operator StringAssertionOperator `json:"operator"`
	Value    string                  `json:"value"`
}

HttpResponseHeaderAssertionSpec defines model for HttpResponseHeaderAssertionSpec.

type HttpResponseJsonBodyAssertion

type HttpResponseJsonBodyAssertion struct {
	Kind HttpResponseJsonBodyAssertionKind `json:"kind"`
	Spec HttpResponseJsonBodyAssertionSpec `json:"spec"`
}

HttpResponseJsonBodyAssertion defines model for HttpResponseJsonBodyAssertion.

type HttpResponseJsonBodyAssertionKind

type HttpResponseJsonBodyAssertionKind string

HttpResponseJsonBodyAssertionKind defines model for HttpResponseJsonBodyAssertion.Kind.

const (
	JsonBody HttpResponseJsonBodyAssertionKind = "json_body"
)

Defines values for HttpResponseJsonBodyAssertionKind.

type HttpResponseJsonBodyAssertionSpec

type HttpResponseJsonBodyAssertionSpec struct {
	JsonPath string                  `json:"jsonPath"`
	Operator StringAssertionOperator `json:"operator"`
	Value    string                  `json:"value"`
}

HttpResponseJsonBodyAssertionSpec defines model for HttpResponseJsonBodyAssertionSpec.

type HttpResponseStatusCodeAssertion

type HttpResponseStatusCodeAssertion struct {
	Kind HttpResponseStatusCodeAssertionKind `json:"kind"`
	Spec HttpResponseStatusCodeAssertionSpec `json:"spec"`
}

HttpResponseStatusCodeAssertion defines model for HttpResponseStatusCodeAssertion.

type HttpResponseStatusCodeAssertionKind

type HttpResponseStatusCodeAssertionKind string

HttpResponseStatusCodeAssertionKind defines model for HttpResponseStatusCodeAssertion.Kind.

const (
	StatusCode HttpResponseStatusCodeAssertionKind = "status_code"
)

Defines values for HttpResponseStatusCodeAssertionKind.

type HttpResponseStatusCodeAssertionSpec

type HttpResponseStatusCodeAssertionSpec struct {
	Operator NumericAssertionOperator `json:"operator"`
	Value    string                   `json:"value"`
}

HttpResponseStatusCodeAssertionSpec defines model for HttpResponseStatusCodeAssertionSpec.

type HttpResponseTextBodyAssertion

type HttpResponseTextBodyAssertion struct {
	Kind HttpResponseTextBodyAssertionKind `json:"kind"`
	Spec HttpResponseTextBodyAssertionSpec `json:"spec"`
}

HttpResponseTextBodyAssertion defines model for HttpResponseTextBodyAssertion.

type HttpResponseTextBodyAssertionKind

type HttpResponseTextBodyAssertionKind string

HttpResponseTextBodyAssertionKind defines model for HttpResponseTextBodyAssertion.Kind.

const (
	TextBody HttpResponseTextBodyAssertionKind = "text_body"
)

Defines values for HttpResponseTextBodyAssertionKind.

type HttpResponseTextBodyAssertionSpec

type HttpResponseTextBodyAssertionSpec struct {
	Operator StringAssertionOperator `json:"operator"`
	Value    string                  `json:"value"`
}

HttpResponseTextBodyAssertionSpec defines model for HttpResponseTextBodyAssertionSpec.

type InstrumentationScope

type InstrumentationScope struct {
	// Attributes Additional attributes that describe the scope. [Optional]. Attribute keys MUST be unique (it is not allowed to have more than one attribute with the same key).
	Attributes             []KeyValue `json:"attributes"`
	DroppedAttributesCount *int64     `json:"droppedAttributesCount,omitempty"`

	// Name An empty instrumentation scope name means the name is unknown.
	Name    *string `json:"name,omitempty"`
	Version *string `json:"version,omitempty"`
}

InstrumentationScope InstrumentationScope is a message representing the instrumentation scope information such as the fully qualified name and version.

type InviteMemberRequest added in v1.4.0

type InviteMemberRequest struct {
	EmailAddress string `json:"emailAddress"`
	Role         string `json:"role"`
}

InviteMemberRequest defines model for InviteMemberRequest.

type Iter

type Iter[T any] struct {
	// contains filtered or unexported fields
}

Iter provides iteration over paginated API results. Use Next() to advance, Current() to get the item, and Err() to check for errors.

Example:

iter := client.GetSpansIter(ctx, request)
for iter.Next() {
    span := iter.Current()
    // process span
}
if err := iter.Err(); err != nil {
    // handle error
}

Iterators are not thread-safe. Do not share an iterator across goroutines.

func (*Iter[T]) Current

func (it *Iter[T]) Current() *T

Current returns the current item in the iteration. Returns nil if Next() has not been called or returned false.

func (*Iter[T]) Err

func (it *Iter[T]) Err() error

Err returns any error that occurred during iteration. Should be checked after Next() returns false.

func (*Iter[T]) Next

func (it *Iter[T]) Next() bool

Next advances the iterator to the next item. Returns true if there is a next item, false if iteration is complete or an error occurred.

type KeyValue

type KeyValue struct {
	Key string `json:"key"`

	// Value AnyValue is used to represent any type of attribute value. AnyValue may contain a primitive value such as a string or integer or it may contain an arbitrary nested object containing arrays, key-value lists and primitives.
	Value AnyValue `json:"value"`
}

KeyValue KeyValue is a key-value pair that is used to store Span attributes, Link attributes, etc.

type LogRecord

type LogRecord struct {
	Attributes []KeyValue `json:"attributes"`

	// Body AnyValue is used to represent any type of attribute value. AnyValue may contain a primitive value such as a string or integer or it may contain an arbitrary nested object containing arrays, key-value lists and primitives.
	Body *AnyValue `json:"body,omitempty"`

	// Dash0EventId The ID of the log record. This is a non-standard OTLP field. The property is only included when
	// `includeOTLPSchemaExtensions` is `true`.
	Dash0EventId           *string `json:"dash0EventId,omitempty"`
	DroppedAttributesCount *int64  `json:"droppedAttributesCount,omitempty"`
	EventName              *string `json:"eventName,omitempty"`
	Flags                  *int64  `json:"flags,omitempty"`

	// Id The ID of the log record. This is a non-standard OTLP field. The property is only included when
	// `includeOTLPSchemaExtensions` is `true`.
	Id                   *string `json:"id,omitempty"`
	ObservedTimeUnixNano string  `json:"observedTimeUnixNano"`

	// SeverityNumber SEVERITY_NUMBER_UNSPECIFIED = 0;
	// SEVERITY_NUMBER_TRACE  = 1;
	// SEVERITY_NUMBER_TRACE2 = 2;
	// SEVERITY_NUMBER_TRACE3 = 3;
	// SEVERITY_NUMBER_TRACE4 = 4;
	// SEVERITY_NUMBER_DEBUG  = 5;
	// SEVERITY_NUMBER_DEBUG2 = 6;
	// SEVERITY_NUMBER_DEBUG3 = 7;
	// SEVERITY_NUMBER_DEBUG4 = 8;
	// SEVERITY_NUMBER_INFO   = 9;
	// SEVERITY_NUMBER_INFO2  = 10;
	// SEVERITY_NUMBER_INFO3  = 11;
	// SEVERITY_NUMBER_INFO4  = 12;
	// SEVERITY_NUMBER_WARN   = 13;
	// SEVERITY_NUMBER_WARN2  = 14;
	// SEVERITY_NUMBER_WARN3  = 15;
	// SEVERITY_NUMBER_WARN4  = 16;
	// SEVERITY_NUMBER_ERROR  = 17;
	// SEVERITY_NUMBER_ERROR2 = 18;
	// SEVERITY_NUMBER_ERROR3 = 19;
	// SEVERITY_NUMBER_ERROR4 = 20;
	// SEVERITY_NUMBER_FATAL  = 21;
	// SEVERITY_NUMBER_FATAL2 = 22;
	// SEVERITY_NUMBER_FATAL3 = 23;
	// SEVERITY_NUMBER_FATAL4 = 24;
	SeverityNumber *SeverityNumber `json:"severityNumber,omitempty"`
	SeverityText   *string         `json:"severityText,omitempty"`
	SpanId         *[]byte         `json:"spanId,omitempty"`
	TimeUnixNano   string          `json:"timeUnixNano"`
	TraceId        *[]byte         `json:"traceId,omitempty"`
}

LogRecord defines model for LogRecord.

type MemberDefinition added in v1.4.0

type MemberDefinition struct {
	Kind     MemberDefinitionKind `json:"kind"`
	Metadata MemberMetadata       `json:"metadata"`
	Spec     MemberSpec           `json:"spec"`
}

MemberDefinition defines model for MemberDefinition.

type MemberDefinitionKind added in v1.4.0

type MemberDefinitionKind string

MemberDefinitionKind defines model for MemberDefinition.Kind.

const (
	Dash0Member MemberDefinitionKind = "Dash0Member"
)

Defines values for MemberDefinitionKind.

type MemberDisplay added in v1.4.0

type MemberDisplay struct {
	Email     *string `json:"email,omitempty"`
	FirstName *string `json:"firstName,omitempty"`
	ImageUrl  *string `json:"imageUrl,omitempty"`
	LastName  *string `json:"lastName,omitempty"`
}

MemberDisplay defines model for MemberDisplay.

type MemberLabels added in v1.4.0

type MemberLabels struct {
	Dash0Comid       *string    `json:"dash0.com/id,omitempty"`
	Dash0ComjoinedAt *time.Time `json:"dash0.com/joinedAt,omitempty"`
}

MemberLabels defines model for MemberLabels.

type MemberMetadata added in v1.4.0

type MemberMetadata struct {
	Labels *MemberLabels `json:"labels,omitempty"`
	Name   string        `json:"name"`
}

MemberMetadata defines model for MemberMetadata.

type MemberSpec added in v1.4.0

type MemberSpec struct {
	Display MemberDisplay `json:"display"`
}

MemberSpec defines model for MemberSpec.

type NameValuePair

type NameValuePair struct {
	Name  string `json:"name"`
	Value string `json:"value"`
}

NameValuePair defines model for NameValuePair.

type NextCursors

type NextCursors struct {
	// After The cursor to another set of results. The value of this field is opaque to the
	// client and may be used as a parameter to the next request to get the another set of results.
	// Cursors do not implement any ordering.
	After *Cursor `json:"after,omitempty"`

	// Before The cursor to another set of results. The value of this field is opaque to the
	// client and may be used as a parameter to the next request to get the another set of results.
	// Cursors do not implement any ordering.
	Before *Cursor `json:"before,omitempty"`
}

NextCursors defines model for NextCursors.

type NumericAssertionOperator

type NumericAssertionOperator string

NumericAssertionOperator defines model for NumericAssertionOperator.

const (
	NumericAssertionOperatorGt         NumericAssertionOperator = "gt"
	NumericAssertionOperatorGte        NumericAssertionOperator = "gte"
	NumericAssertionOperatorIs         NumericAssertionOperator = "is"
	NumericAssertionOperatorIsNot      NumericAssertionOperator = "is_not"
	NumericAssertionOperatorIsNotOneOf NumericAssertionOperator = "is_not_one_of"
	NumericAssertionOperatorIsOneOf    NumericAssertionOperator = "is_one_of"
	NumericAssertionOperatorLt         NumericAssertionOperator = "lt"
	NumericAssertionOperatorLte        NumericAssertionOperator = "lte"
)

Defines values for NumericAssertionOperator.

type OAuthAuthorizationServerMetadata added in v1.6.0

type OAuthAuthorizationServerMetadata struct {
	// AuthorizationEndpoint URL of the authorization endpoint.
	AuthorizationEndpoint string `json:"authorization_endpoint"`

	// CodeChallengeMethodsSupported List of supported PKCE code challenge methods.
	CodeChallengeMethodsSupported *[]OAuthCodeChallengeMethod `json:"code_challenge_methods_supported,omitempty"`

	// GrantTypesSupported List of supported grant types.
	GrantTypesSupported *[]OAuthGrantType `json:"grant_types_supported,omitempty"`

	// IntrospectionEndpoint URL of the token introspection endpoint.
	IntrospectionEndpoint *string `json:"introspection_endpoint,omitempty"`

	// Issuer The authorization server's issuer identifier (URL).
	Issuer string `json:"issuer"`

	// RegistrationEndpoint URL of the dynamic client registration endpoint.
	RegistrationEndpoint *string `json:"registration_endpoint,omitempty"`

	// ResponseTypesSupported List of supported response types.
	ResponseTypesSupported []OAuthResponseType `json:"response_types_supported"`

	// RevocationEndpoint URL of the token revocation endpoint.
	RevocationEndpoint *string `json:"revocation_endpoint,omitempty"`

	// ScopesSupported List of scopes supported by the authorization server.
	ScopesSupported *[]string `json:"scopes_supported,omitempty"`

	// TokenEndpoint URL of the token endpoint.
	TokenEndpoint string `json:"token_endpoint"`

	// TokenEndpointAuthMethodsSupported List of supported token endpoint authentication methods.
	TokenEndpointAuthMethodsSupported *[]OAuthTokenEndpointAuthMethod `json:"token_endpoint_auth_methods_supported,omitempty"`
}

OAuthAuthorizationServerMetadata defines model for OAuthAuthorizationServerMetadata.

type OAuthClientRegistrationRequest added in v1.6.0

type OAuthClientRegistrationRequest struct {
	// ClientName Human-readable name of the client.
	ClientName string `json:"client_name"`

	// ClientUri URL of the client's home page.
	ClientUri *string `json:"client_uri,omitempty"`

	// GrantTypes Grant types the client intends to use.
	GrantTypes *[]OAuthGrantType `json:"grant_types,omitempty"`

	// LogoUri URL of the client's logo image.
	LogoUri *string `json:"logo_uri,omitempty"`

	// RedirectUris Array of allowed redirect URIs.
	RedirectUris []string `json:"redirect_uris"`

	// ResponseTypes Response types the client intends to use.
	ResponseTypes *[]OAuthResponseType `json:"response_types,omitempty"`

	// Scope Space-separated list of scopes the client is requesting.
	Scope *string `json:"scope,omitempty"`

	// TokenEndpointAuthMethod - `none`: Public client, no client authentication (used by CLI/MCP clients).
	// Only public clients are supported. This deviates from RFC 7591 which defaults
	// to `client_secret_basic` when omitted.
	TokenEndpointAuthMethod *OAuthTokenEndpointAuthMethod `json:"token_endpoint_auth_method,omitempty"`
}

OAuthClientRegistrationRequest defines model for OAuthClientRegistrationRequest.

type OAuthClientRegistrationResponse added in v1.6.0

type OAuthClientRegistrationResponse struct {
	// ClientId Unique client identifier issued by the authorization server.
	ClientId string `json:"client_id"`

	// ClientName Human-readable name of the client.
	ClientName string `json:"client_name"`

	// ClientUri URL of the client's home page.
	ClientUri *string `json:"client_uri,omitempty"`

	// GrantTypes Grant types the client is registered for.
	GrantTypes *[]OAuthGrantType `json:"grant_types,omitempty"`

	// LogoUri URL of the client's logo image.
	LogoUri *string `json:"logo_uri,omitempty"`

	// RedirectUris Array of allowed redirect URIs.
	RedirectUris []string `json:"redirect_uris"`

	// RegistrationAccessToken Token for managing this client registration (RFC 7592).
	RegistrationAccessToken string `json:"registration_access_token"`

	// ResponseTypes Response types the client is registered for.
	ResponseTypes *[]OAuthResponseType `json:"response_types,omitempty"`

	// Scope Space-separated list of scopes the client is registered for.
	Scope *string `json:"scope,omitempty"`

	// TokenEndpointAuthMethod - `none`: Public client, no client authentication (used by CLI/MCP clients).
	// Only public clients are supported. This deviates from RFC 7591 which defaults
	// to `client_secret_basic` when omitted.
	TokenEndpointAuthMethod *OAuthTokenEndpointAuthMethod `json:"token_endpoint_auth_method,omitempty"`
}

OAuthClientRegistrationResponse defines model for OAuthClientRegistrationResponse.

type OAuthCodeChallengeMethod added in v1.6.0

type OAuthCodeChallengeMethod string

OAuthCodeChallengeMethod - `S256`: SHA-256 based code challenge method for PKCE (RFC 7636 section 4.2).

const (
	S256 OAuthCodeChallengeMethod = "S256"
)

Defines values for OAuthCodeChallengeMethod.

type OAuthGrantType added in v1.6.0

type OAuthGrantType string

OAuthGrantType - `authorization_code`: The standard authorization code grant (RFC 6749 section 4.1). - `refresh_token`: Exchange a refresh token for new tokens (RFC 6749 section 6).

const (
	OAuthGrantTypeAuthorizationCode OAuthGrantType = "authorization_code"
	OAuthGrantTypeRefreshToken      OAuthGrantType = "refresh_token"
)

Defines values for OAuthGrantType.

type OAuthProtectedResourceMetadata added in v1.6.0

type OAuthProtectedResourceMetadata struct {
	// AuthorizationServers Array of authorization server issuer identifiers that can issue tokens accepted by this resource.
	AuthorizationServers []string `json:"authorization_servers"`

	// BearerMethodsSupported Methods supported for sending bearer tokens to this resource (e.g., "header").
	BearerMethodsSupported *[]string `json:"bearer_methods_supported,omitempty"`

	// Resource The resource server's resource identifier (its canonical URI).
	Resource string `json:"resource"`

	// ResourceDocumentation URL of documentation for this protected resource.
	ResourceDocumentation *string `json:"resource_documentation,omitempty"`

	// ScopesSupported List of scopes supported by this resource server.
	ScopesSupported *[]string `json:"scopes_supported,omitempty"`
}

OAuthProtectedResourceMetadata defines model for OAuthProtectedResourceMetadata.

type OAuthResponseType added in v1.6.0

type OAuthResponseType string

OAuthResponseType - `code`: The authorization code response type (RFC 6749 section 4.1.1).

const (
	Code OAuthResponseType = "code"
)

Defines values for OAuthResponseType.

type OAuthRevocationRequest added in v1.6.0

type OAuthRevocationRequest struct {
	// Token The token to be revoked.
	Token string `json:"token"`

	// TokenTypeHint - `access_token`: An OAuth 2.0 access token.
	// - `refresh_token`: An OAuth 2.0 refresh token.
	TokenTypeHint *OAuthTokenType `json:"token_type_hint,omitempty"`
}

OAuthRevocationRequest defines model for OAuthRevocationRequest.

type OAuthTokenEndpointAuthMethod added in v1.6.0

type OAuthTokenEndpointAuthMethod string

OAuthTokenEndpointAuthMethod - `none`: Public client, no client authentication (used by CLI/MCP clients). Only public clients are supported. This deviates from RFC 7591 which defaults to `client_secret_basic` when omitted.

const (
	None OAuthTokenEndpointAuthMethod = "none"
)

Defines values for OAuthTokenEndpointAuthMethod.

type OAuthTokenErrorResponse added in v1.6.0

type OAuthTokenErrorResponse struct {
	// Error A single ASCII error code. Standard values include:
	// invalid_request, invalid_client, invalid_grant, unauthorized_client,
	// unsupported_grant_type, invalid_scope.
	Error string `json:"error"`

	// ErrorDescription Human-readable description providing additional information.
	ErrorDescription *string `json:"error_description,omitempty"`

	// ErrorUri URI identifying a human-readable web page with error information.
	ErrorUri *string `json:"error_uri,omitempty"`
}

OAuthTokenErrorResponse defines model for OAuthTokenErrorResponse.

type OAuthTokenRequest added in v1.6.0

type OAuthTokenRequest struct {
	// ClientId The client identifier.
	ClientId *string `json:"client_id,omitempty"`

	// Code The authorization code (required for authorization_code grant).
	Code *string `json:"code,omitempty"`

	// CodeVerifier PKCE code verifier (required for authorization_code grant). All public clients must use PKCE (RFC 7636).
	CodeVerifier *string `json:"code_verifier,omitempty"`

	// GrantType - `authorization_code`: The standard authorization code grant (RFC 6749 section 4.1).
	// - `refresh_token`: Exchange a refresh token for new tokens (RFC 6749 section 6).
	GrantType OAuthGrantType `json:"grant_type"`

	// RedirectUri Must match the redirect_uri used in the authorization request (required for authorization_code grant).
	RedirectUri *string `json:"redirect_uri,omitempty"`

	// RefreshToken The refresh token (required for refresh_token grant).
	RefreshToken *string `json:"refresh_token,omitempty"`

	// Scope Space-separated list of requested scopes. For refresh_token grant, must be equal to or a subset of the originally granted scopes.
	Scope *string `json:"scope,omitempty"`
}

OAuthTokenRequest defines model for OAuthTokenRequest.

type OAuthTokenResponse added in v1.6.0

type OAuthTokenResponse struct {
	// AccessToken The access token issued by the authorization server.
	AccessToken        string              `json:"access_token"`
	DatasetRestriction *DatasetRestriction `json:"dataset_restriction,omitempty"`
	Datasets           *[]string           `json:"datasets,omitempty"`

	// ExpiresIn Lifetime of the access token in seconds.
	ExpiresIn int64 `json:"expires_in"`

	// RefreshToken The refresh token for obtaining new access tokens.
	RefreshToken *string `json:"refresh_token,omitempty"`

	// Scope Space-separated list of granted scopes.
	Scope *string `json:"scope,omitempty"`

	// TokenType The type of token issued (always "Bearer").
	TokenType string `json:"token_type"`
}

OAuthTokenResponse defines model for OAuthTokenResponse.

type OAuthTokenType added in v1.6.0

type OAuthTokenType string

OAuthTokenType - `access_token`: An OAuth 2.0 access token. - `refresh_token`: An OAuth 2.0 refresh token.

const (
	OAuthTokenTypeAccessToken  OAuthTokenType = "access_token"
	OAuthTokenTypeRefreshToken OAuthTokenType = "refresh_token"
)

Defines values for OAuthTokenType.

type OrderingCriteria

type OrderingCriteria = []OrderingCriterion

OrderingCriteria Any supported attribute keys to order by.

type OrderingCriterion

type OrderingCriterion struct {
	Direction OrderingDirection `json:"direction"`

	// Key Any attribute key to order by.
	Key OrderingKey `json:"key"`
}

OrderingCriterion Any combination of a supported key to order by and a direction.

type OrderingDirection

type OrderingDirection string

OrderingDirection defines model for OrderingDirection.

const (
	Ascending  OrderingDirection = "ascending"
	Descending OrderingDirection = "descending"
)

Defines values for OrderingDirection.

type OrderingKey

type OrderingKey = string

OrderingKey Any attribute key to order by.

type OtlpEncoding added in v1.2.0

type OtlpEncoding string

OtlpEncoding specifies the wire format for OTLP data.

const (
	// OtlpEncodingJson is the OTLP/JSON encoding over HTTP.
	OtlpEncodingJson OtlpEncoding = "otlp/json"
)

type PersesDashboard added in v1.6.0

type PersesDashboard struct {
	APIVersion string                  `json:"apiVersion"`
	Kind       string                  `json:"kind"`
	Metadata   PersesDashboardMetadata `json:"metadata"`
	Spec       map[string]interface{}  `json:"spec"`
}

PersesDashboard represents the Perses Operator PersesDashboard CRD (perses.dev/v1alpha1 and perses.dev/v1alpha2).

type PersesDashboardMetadata added in v1.6.0

type PersesDashboardMetadata struct {
	Name        string            `json:"name,omitempty"`
	Namespace   string            `json:"namespace,omitempty"`
	Labels      map[string]string `json:"labels,omitempty"`
	Annotations map[string]string `json:"annotations,omitempty"`
}

PersesDashboardMetadata contains metadata for a PersesDashboard.

type PostApiAlertingCheckRulesJSONRequestBody

type PostApiAlertingCheckRulesJSONRequestBody = PrometheusAlertRule

PostApiAlertingCheckRulesJSONRequestBody defines body for PostApiAlertingCheckRules for application/json ContentType.

type PostApiAlertingCheckRulesParams

type PostApiAlertingCheckRulesParams struct {
	// Dataset The associated dataset.
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiAlertingCheckRulesParams defines parameters for PostApiAlertingCheckRules.

type PostApiAlertingCheckRulesResponse

type PostApiAlertingCheckRulesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *PrometheusAlertRule
	JSONDefault  *ErrorResponse
}

func ParsePostApiAlertingCheckRulesResponse

func ParsePostApiAlertingCheckRulesResponse(rsp *http.Response) (*PostApiAlertingCheckRulesResponse, error)

ParsePostApiAlertingCheckRulesResponse parses an HTTP response from a PostApiAlertingCheckRulesWithResponse call

func (PostApiAlertingCheckRulesResponse) Status

Status returns HTTPResponse.Status

func (PostApiAlertingCheckRulesResponse) StatusCode

func (r PostApiAlertingCheckRulesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiDashboardsJSONRequestBody

type PostApiDashboardsJSONRequestBody = DashboardDefinition

PostApiDashboardsJSONRequestBody defines body for PostApiDashboards for application/json ContentType.

type PostApiDashboardsParams

type PostApiDashboardsParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiDashboardsParams defines parameters for PostApiDashboards.

type PostApiDashboardsResponse

type PostApiDashboardsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *DashboardDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiDashboardsResponse

func ParsePostApiDashboardsResponse(rsp *http.Response) (*PostApiDashboardsResponse, error)

ParsePostApiDashboardsResponse parses an HTTP response from a PostApiDashboardsWithResponse call

func (PostApiDashboardsResponse) Status

func (r PostApiDashboardsResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiDashboardsResponse) StatusCode

func (r PostApiDashboardsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiImportCheckRuleJSONRequestBody

type PostApiImportCheckRuleJSONRequestBody = PrometheusAlertRule

PostApiImportCheckRuleJSONRequestBody defines body for PostApiImportCheckRule for application/json ContentType.

type PostApiImportCheckRuleParams

type PostApiImportCheckRuleParams struct {
	// Dataset The associated dataset.
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiImportCheckRuleParams defines parameters for PostApiImportCheckRule.

type PostApiImportCheckRuleResponse

type PostApiImportCheckRuleResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *PrometheusAlertRule
	JSONDefault  *ErrorResponse
}

func ParsePostApiImportCheckRuleResponse

func ParsePostApiImportCheckRuleResponse(rsp *http.Response) (*PostApiImportCheckRuleResponse, error)

ParsePostApiImportCheckRuleResponse parses an HTTP response from a PostApiImportCheckRuleWithResponse call

func (PostApiImportCheckRuleResponse) Status

Status returns HTTPResponse.Status

func (PostApiImportCheckRuleResponse) StatusCode

func (r PostApiImportCheckRuleResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiImportDashboardJSONRequestBody

type PostApiImportDashboardJSONRequestBody = DashboardDefinition

PostApiImportDashboardJSONRequestBody defines body for PostApiImportDashboard for application/json ContentType.

type PostApiImportDashboardParams

type PostApiImportDashboardParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiImportDashboardParams defines parameters for PostApiImportDashboard.

type PostApiImportDashboardResponse

type PostApiImportDashboardResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *DashboardDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiImportDashboardResponse

func ParsePostApiImportDashboardResponse(rsp *http.Response) (*PostApiImportDashboardResponse, error)

ParsePostApiImportDashboardResponse parses an HTTP response from a PostApiImportDashboardWithResponse call

func (PostApiImportDashboardResponse) Status

Status returns HTTPResponse.Status

func (PostApiImportDashboardResponse) StatusCode

func (r PostApiImportDashboardResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiImportSyntheticCheckJSONRequestBody

type PostApiImportSyntheticCheckJSONRequestBody = SyntheticCheckDefinition

PostApiImportSyntheticCheckJSONRequestBody defines body for PostApiImportSyntheticCheck for application/json ContentType.

type PostApiImportSyntheticCheckParams

type PostApiImportSyntheticCheckParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiImportSyntheticCheckParams defines parameters for PostApiImportSyntheticCheck.

type PostApiImportSyntheticCheckResponse

type PostApiImportSyntheticCheckResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SyntheticCheckDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiImportSyntheticCheckResponse

func ParsePostApiImportSyntheticCheckResponse(rsp *http.Response) (*PostApiImportSyntheticCheckResponse, error)

ParsePostApiImportSyntheticCheckResponse parses an HTTP response from a PostApiImportSyntheticCheckWithResponse call

func (PostApiImportSyntheticCheckResponse) Status

Status returns HTTPResponse.Status

func (PostApiImportSyntheticCheckResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type PostApiImportViewJSONRequestBody

type PostApiImportViewJSONRequestBody = ViewDefinition

PostApiImportViewJSONRequestBody defines body for PostApiImportView for application/json ContentType.

type PostApiImportViewParams

type PostApiImportViewParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiImportViewParams defines parameters for PostApiImportView.

type PostApiImportViewResponse

type PostApiImportViewResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *ViewDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiImportViewResponse

func ParsePostApiImportViewResponse(rsp *http.Response) (*PostApiImportViewResponse, error)

ParsePostApiImportViewResponse parses an HTTP response from a PostApiImportViewWithResponse call

func (PostApiImportViewResponse) Status

func (r PostApiImportViewResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiImportViewResponse) StatusCode

func (r PostApiImportViewResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiLogsJSONRequestBody

type PostApiLogsJSONRequestBody = GetLogRecordsRequest

PostApiLogsJSONRequestBody defines body for PostApiLogs for application/json ContentType.

type PostApiLogsResponse

type PostApiLogsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *GetLogRecordsResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiLogsResponse

func ParsePostApiLogsResponse(rsp *http.Response) (*PostApiLogsResponse, error)

ParsePostApiLogsResponse parses an HTTP response from a PostApiLogsWithResponse call

func (PostApiLogsResponse) Status

func (r PostApiLogsResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiLogsResponse) StatusCode

func (r PostApiLogsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiMembersJSONRequestBody added in v1.4.0

type PostApiMembersJSONRequestBody = InviteMemberRequest

PostApiMembersJSONRequestBody defines body for PostApiMembers for application/json ContentType.

type PostApiMembersResponse added in v1.4.0

type PostApiMembersResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParsePostApiMembersResponse added in v1.4.0

func ParsePostApiMembersResponse(rsp *http.Response) (*PostApiMembersResponse, error)

ParsePostApiMembersResponse parses an HTTP response from a PostApiMembersWithResponse call

func (PostApiMembersResponse) Status added in v1.4.0

func (r PostApiMembersResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiMembersResponse) StatusCode added in v1.4.0

func (r PostApiMembersResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiRecordingRuleGroupsJSONRequestBody added in v1.6.0

type PostApiRecordingRuleGroupsJSONRequestBody = RecordingRuleGroupCreateRequest

PostApiRecordingRuleGroupsJSONRequestBody defines body for PostApiRecordingRuleGroups for application/json ContentType.

type PostApiRecordingRuleGroupsResponse added in v1.6.0

type PostApiRecordingRuleGroupsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON201      *RecordingRuleGroupResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiRecordingRuleGroupsResponse added in v1.6.0

func ParsePostApiRecordingRuleGroupsResponse(rsp *http.Response) (*PostApiRecordingRuleGroupsResponse, error)

ParsePostApiRecordingRuleGroupsResponse parses an HTTP response from a PostApiRecordingRuleGroupsWithResponse call

func (PostApiRecordingRuleGroupsResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (PostApiRecordingRuleGroupsResponse) StatusCode added in v1.6.0

func (r PostApiRecordingRuleGroupsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiSamplingRulesJSONRequestBody added in v1.1.0

type PostApiSamplingRulesJSONRequestBody = SamplingRuleCreateRequest

PostApiSamplingRulesJSONRequestBody defines body for PostApiSamplingRules for application/json ContentType.

type PostApiSamplingRulesParams added in v1.1.0

type PostApiSamplingRulesParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiSamplingRulesParams defines parameters for PostApiSamplingRules.

type PostApiSamplingRulesResponse added in v1.1.0

type PostApiSamplingRulesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SamplingRuleResponse
	JSON403      *ErrorResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiSamplingRulesResponse added in v1.1.0

func ParsePostApiSamplingRulesResponse(rsp *http.Response) (*PostApiSamplingRulesResponse, error)

ParsePostApiSamplingRulesResponse parses an HTTP response from a PostApiSamplingRulesWithResponse call

func (PostApiSamplingRulesResponse) Status added in v1.1.0

Status returns HTTPResponse.Status

func (PostApiSamplingRulesResponse) StatusCode added in v1.1.0

func (r PostApiSamplingRulesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiSpansJSONRequestBody

type PostApiSpansJSONRequestBody = GetSpansRequest

PostApiSpansJSONRequestBody defines body for PostApiSpans for application/json ContentType.

type PostApiSpansResponse

type PostApiSpansResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *GetSpansResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiSpansResponse

func ParsePostApiSpansResponse(rsp *http.Response) (*PostApiSpansResponse, error)

ParsePostApiSpansResponse parses an HTTP response from a PostApiSpansWithResponse call

func (PostApiSpansResponse) Status

func (r PostApiSpansResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiSpansResponse) StatusCode

func (r PostApiSpansResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiSqlJSONRequestBody added in v1.6.0

type PostApiSqlJSONRequestBody = ExecuteSqlRequest

PostApiSqlJSONRequestBody defines body for PostApiSql for application/json ContentType.

type PostApiSqlResponse added in v1.6.0

type PostApiSqlResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *ExecuteSqlResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiSqlResponse added in v1.6.0

func ParsePostApiSqlResponse(rsp *http.Response) (*PostApiSqlResponse, error)

ParsePostApiSqlResponse parses an HTTP response from a PostApiSqlWithResponse call

func (PostApiSqlResponse) Status added in v1.6.0

func (r PostApiSqlResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiSqlResponse) StatusCode added in v1.6.0

func (r PostApiSqlResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiSyntheticChecksJSONRequestBody

type PostApiSyntheticChecksJSONRequestBody = SyntheticCheckDefinition

PostApiSyntheticChecksJSONRequestBody defines body for PostApiSyntheticChecks for application/json ContentType.

type PostApiSyntheticChecksParams

type PostApiSyntheticChecksParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiSyntheticChecksParams defines parameters for PostApiSyntheticChecks.

type PostApiSyntheticChecksResponse

type PostApiSyntheticChecksResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SyntheticCheckDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiSyntheticChecksResponse

func ParsePostApiSyntheticChecksResponse(rsp *http.Response) (*PostApiSyntheticChecksResponse, error)

ParsePostApiSyntheticChecksResponse parses an HTTP response from a PostApiSyntheticChecksWithResponse call

func (PostApiSyntheticChecksResponse) Status

Status returns HTTPResponse.Status

func (PostApiSyntheticChecksResponse) StatusCode

func (r PostApiSyntheticChecksResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiSyntheticChecksTestJSONRequestBody added in v1.4.0

type PostApiSyntheticChecksTestJSONRequestBody = TestSyntheticCheckRequest

PostApiSyntheticChecksTestJSONRequestBody defines body for PostApiSyntheticChecksTest for application/json ContentType.

type PostApiSyntheticChecksTestResponse added in v1.4.0

type PostApiSyntheticChecksTestResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *TestSyntheticCheckResponse
	JSONDefault  *ErrorResponse
}

func ParsePostApiSyntheticChecksTestResponse added in v1.4.0

func ParsePostApiSyntheticChecksTestResponse(rsp *http.Response) (*PostApiSyntheticChecksTestResponse, error)

ParsePostApiSyntheticChecksTestResponse parses an HTTP response from a PostApiSyntheticChecksTestWithResponse call

func (PostApiSyntheticChecksTestResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (PostApiSyntheticChecksTestResponse) StatusCode added in v1.4.0

func (r PostApiSyntheticChecksTestResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiTeamsJSONRequestBody added in v1.4.0

type PostApiTeamsJSONRequestBody = TeamDefinition

PostApiTeamsJSONRequestBody defines body for PostApiTeams for application/json ContentType.

type PostApiTeamsOriginOrIdMembersJSONRequestBody added in v1.4.0

type PostApiTeamsOriginOrIdMembersJSONRequestBody = AddTeamMembersRequest

PostApiTeamsOriginOrIdMembersJSONRequestBody defines body for PostApiTeamsOriginOrIdMembers for application/json ContentType.

type PostApiTeamsOriginOrIdMembersResponse added in v1.4.0

type PostApiTeamsOriginOrIdMembersResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParsePostApiTeamsOriginOrIdMembersResponse added in v1.4.0

func ParsePostApiTeamsOriginOrIdMembersResponse(rsp *http.Response) (*PostApiTeamsOriginOrIdMembersResponse, error)

ParsePostApiTeamsOriginOrIdMembersResponse parses an HTTP response from a PostApiTeamsOriginOrIdMembersWithResponse call

func (PostApiTeamsOriginOrIdMembersResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (PostApiTeamsOriginOrIdMembersResponse) StatusCode added in v1.4.0

StatusCode returns HTTPResponse.StatusCode

type PostApiTeamsResponse added in v1.4.0

type PostApiTeamsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *TeamDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiTeamsResponse added in v1.4.0

func ParsePostApiTeamsResponse(rsp *http.Response) (*PostApiTeamsResponse, error)

ParsePostApiTeamsResponse parses an HTTP response from a PostApiTeamsWithResponse call

func (PostApiTeamsResponse) Status added in v1.4.0

func (r PostApiTeamsResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiTeamsResponse) StatusCode added in v1.4.0

func (r PostApiTeamsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostApiViewsJSONRequestBody

type PostApiViewsJSONRequestBody = ViewDefinition

PostApiViewsJSONRequestBody defines body for PostApiViews for application/json ContentType.

type PostApiViewsParams

type PostApiViewsParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PostApiViewsParams defines parameters for PostApiViews.

type PostApiViewsResponse

type PostApiViewsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *ViewDefinition
	JSONDefault  *ErrorResponse
}

func ParsePostApiViewsResponse

func ParsePostApiViewsResponse(rsp *http.Response) (*PostApiViewsResponse, error)

ParsePostApiViewsResponse parses an HTTP response from a PostApiViewsWithResponse call

func (PostApiViewsResponse) Status

func (r PostApiViewsResponse) Status() string

Status returns HTTPResponse.Status

func (PostApiViewsResponse) StatusCode

func (r PostApiViewsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostOauthRegisterJSONRequestBody added in v1.6.0

type PostOauthRegisterJSONRequestBody = OAuthClientRegistrationRequest

PostOauthRegisterJSONRequestBody defines body for PostOauthRegister for application/json ContentType.

type PostOauthRegisterResponse added in v1.6.0

type PostOauthRegisterResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON201      *OAuthClientRegistrationResponse
	JSONDefault  *ErrorResponse
}

func ParsePostOauthRegisterResponse added in v1.6.0

func ParsePostOauthRegisterResponse(rsp *http.Response) (*PostOauthRegisterResponse, error)

ParsePostOauthRegisterResponse parses an HTTP response from a PostOauthRegisterWithResponse call

func (PostOauthRegisterResponse) Status added in v1.6.0

func (r PostOauthRegisterResponse) Status() string

Status returns HTTPResponse.Status

func (PostOauthRegisterResponse) StatusCode added in v1.6.0

func (r PostOauthRegisterResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostOauthRevokeFormdataRequestBody added in v1.6.0

type PostOauthRevokeFormdataRequestBody = OAuthRevocationRequest

PostOauthRevokeFormdataRequestBody defines body for PostOauthRevoke for application/x-www-form-urlencoded ContentType.

type PostOauthRevokeResponse added in v1.6.0

type PostOauthRevokeResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParsePostOauthRevokeResponse added in v1.6.0

func ParsePostOauthRevokeResponse(rsp *http.Response) (*PostOauthRevokeResponse, error)

ParsePostOauthRevokeResponse parses an HTTP response from a PostOauthRevokeWithResponse call

func (PostOauthRevokeResponse) Status added in v1.6.0

func (r PostOauthRevokeResponse) Status() string

Status returns HTTPResponse.Status

func (PostOauthRevokeResponse) StatusCode added in v1.6.0

func (r PostOauthRevokeResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PostOauthTokenFormdataRequestBody added in v1.6.0

type PostOauthTokenFormdataRequestBody = OAuthTokenRequest

PostOauthTokenFormdataRequestBody defines body for PostOauthToken for application/x-www-form-urlencoded ContentType.

type PostOauthTokenResponse added in v1.6.0

type PostOauthTokenResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *OAuthTokenResponse
	JSON400      *OAuthTokenErrorResponse
	JSONDefault  *ErrorResponse
}

func ParsePostOauthTokenResponse added in v1.6.0

func ParsePostOauthTokenResponse(rsp *http.Response) (*PostOauthTokenResponse, error)

ParsePostOauthTokenResponse parses an HTTP response from a PostOauthTokenWithResponse call

func (PostOauthTokenResponse) Status added in v1.6.0

func (r PostOauthTokenResponse) Status() string

Status returns HTTPResponse.Status

func (PostOauthTokenResponse) StatusCode added in v1.6.0

func (r PostOauthTokenResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Progress added in v1.6.0

type Progress struct {
	BytesRead           uint64 `json:"bytesRead"`
	ExecutionTimeMillis uint64 `json:"executionTimeMillis"`
	RowsRead            uint64 `json:"rowsRead"`
	TotalRowsToRead     uint64 `json:"totalRowsToRead"`
}

Progress defines model for Progress.

type PrometheusAlertRule

type PrometheusAlertRule struct {
	// Annotations Annotations are key-value pairs that can be used to add additional metadata to a check. They map
	// to Prometheus alerting rules' "annotations" field.
	//
	// The "summary" and "description" annotations are expected and are used as the human-readable
	// summary and description of the check rule.
	Annotations *PrometheusAlertRule_Annotations `json:"annotations,omitempty"`

	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset *Dataset `json:"dataset,omitempty"`

	// Enabled A boolean flag to enable or disable the check rule. When a check rule is disabled, it will not be
	// evaluated, and no check evaluations will be created. This field is optional and defaults to true.
	Enabled *bool `json:"enabled,omitempty"`

	// Expression An editable PromQL expression that can leverage the complete Dash0 Query Language. It furthermore
	// supports a variable called $__threshold.
	//
	// - `$__threshold` can be used as a placeholder for both the degraded and failed thresholds. The
	//   thresholds are defined in the thresholds field. When `$__threshold` is used in the expression,
	//   the `thresholds` field is required and at least one of the thresholds must be defined.
	//
	//   Usage of `$__threshold` implies that the PromQL expression may have to be evaluated up to two
	//   times using the degraded threshold and critical threshold respectively.
	//
	// - Top-level AND statements are treated as enablement conditions that specify when the check should
	//   "be running", i.e., is active. The use-cases for enablement conditions are several, e.g., requiring
	//   a minimum amount of requests being served before triggering due to errors rates,
	//   maintenance windows or muted timeframes.
	Expression string    `json:"expression"`
	For        *Duration `json:"for,omitempty"`

	// Id User defined id for getting/updating/deleting the alert rule through the API.
	Id       *string   `json:"id,omitempty"`
	Interval *Duration `json:"interval,omitempty"`

	KeepFiringFor *Duration `json:"keep_firing_for,omitempty"`

	// Labels Label are key-value pairs that can be used to add additional metadata to a check. They map
	// to Prometheus alerting rules' "labels" field.
	Labels *map[string]string `json:"labels,omitempty"`

	// Name Human-readable and templatable name for the check. In Prometheus alerting rules this is called "alert".
	Name string `json:"name"`

	// Thresholds Thresholds to use for the `$__threshold` variable in the expression field.
	Thresholds *CheckThresholds `json:"thresholds,omitempty"`
}

PrometheusAlertRule Check rules represent a periodically evaluated expression to determine the health of a resource. The result of the evaluation are zero or more CheckEvaluations.

func ConvertPrometheusRuleToPrometheusAlertRule added in v1.6.0

func ConvertPrometheusRuleToPrometheusAlertRule(rule *PrometheusRule, groupInterval time.Duration, ruleID string) (*PrometheusAlertRule, error)

ConvertPrometheusRuleToPrometheusAlertRule converts a Prometheus alerting rule to a Dash0 CheckRule. It extracts Dash0-specific annotations (thresholds, enabled flag) from the rule annotations and maps them to dedicated fields on the returned rule.

type PrometheusAlertRuleApiListItem

type PrometheusAlertRuleApiListItem struct {
	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset Dataset `json:"dataset"`

	// Id The unique identifier of the check rule.
	//
	// For backward compatibility, this field is also filled with the origin, if it exists.
	// However in a future version, this field will only return the actual check rule ID.
	Id string `json:"id"`

	// Name Human-readable and templatable name for the check. In Prometheus alerting rules this is called "alert".
	Name *string `json:"name,omitempty"`

	// Origin User defined origin for getting/updating/deleting the alert rule through the API.
	Origin *string `json:"origin,omitempty"`
}

PrometheusAlertRuleApiListItem The ID, origin, dataset, and the name of a check rule.

type PrometheusAlertRule_Annotations added in v1.6.0

type PrometheusAlertRule_Annotations struct {
	// Description Human-readable and templatable description for the check that allows you to customize the way the
	// rationale of the check is textually described in the Dash0 UI, in notifications, etc. This will
	// be optimized in the design for long form viewing.
	Description *string `json:"description,omitempty"`

	// Summary Human-readable and templatable summary for the check that allows you to customize the way the check
	// is textually described in short form in the Dash0 UI, in notifications, etc.
	Summary              *string           `json:"summary,omitempty"`
	AdditionalProperties map[string]string `json:"-"`
}

PrometheusAlertRule_Annotations Annotations are key-value pairs that can be used to add additional metadata to a check. They map to Prometheus alerting rules' "annotations" field.

The "summary" and "description" annotations are expected and are used as the human-readable summary and description of the check rule.

func (PrometheusAlertRule_Annotations) Get added in v1.6.0

func (a PrometheusAlertRule_Annotations) Get(fieldName string) (value string, found bool)

Getter for additional properties for PrometheusAlertRule_Annotations. Returns the specified element and whether it was found

func (PrometheusAlertRule_Annotations) MarshalJSON added in v1.6.0

func (a PrometheusAlertRule_Annotations) MarshalJSON() ([]byte, error)

Override default JSON handling for PrometheusAlertRule_Annotations to handle AdditionalProperties

func (*PrometheusAlertRule_Annotations) Set added in v1.6.0

func (a *PrometheusAlertRule_Annotations) Set(fieldName string, value string)

Setter for additional properties for PrometheusAlertRule_Annotations

func (*PrometheusAlertRule_Annotations) UnmarshalJSON added in v1.6.0

func (a *PrometheusAlertRule_Annotations) UnmarshalJSON(b []byte) error

Override default JSON handling for PrometheusAlertRule_Annotations to handle AdditionalProperties

type PrometheusRule added in v1.6.0

type PrometheusRule struct {
	Alert         string            `json:"alert"`
	Expr          string            `json:"expr"`
	For           time.Duration     `json:"for,omitempty"`
	KeepFiringFor time.Duration     `json:"keep_firing_for,omitempty"`
	Annotations   map[string]string `json:"annotations"`
	Labels        map[string]string `json:"labels"`
}

PrometheusRule represents a single alerting rule in Prometheus format.

type PrometheusRules added in v1.6.0

type PrometheusRules struct {
	APIVersion string                  `json:"apiVersion"`
	Kind       string                  `json:"kind"`
	Metadata   PrometheusRulesMetadata `json:"metadata"`
	Spec       PrometheusRulesSpec     `json:"spec"`
}

PrometheusRules represents the Kubernetes Prometheus Operator PrometheusRule CRD document. This is the user-facing format used by the Terraform provider and Kubernetes operator.

type PrometheusRulesGroup added in v1.6.0

type PrometheusRulesGroup struct {
	Name     string           `json:"name"`
	Interval time.Duration    `json:"interval,omitempty"`
	Rules    []PrometheusRule `json:"rules"`
}

PrometheusRulesGroup represents a single rule group in Prometheus format.

type PrometheusRulesMetadata added in v1.6.0

type PrometheusRulesMetadata struct {
	Name        string            `json:"name,omitempty"`
	Namespace   string            `json:"namespace,omitempty"`
	Labels      map[string]string `json:"labels,omitempty"`
	Annotations map[string]string `json:"annotations,omitempty"`
}

PrometheusRulesMetadata contains Kubernetes-style metadata for a PrometheusRules document.

type PrometheusRulesSpec added in v1.6.0

type PrometheusRulesSpec struct {
	Groups []PrometheusRulesGroup `json:"groups"`
}

PrometheusRulesSpec contains the groups of rules.

type PutApiAlertingCheckRulesOriginOrIdJSONRequestBody

type PutApiAlertingCheckRulesOriginOrIdJSONRequestBody = PrometheusAlertRule

PutApiAlertingCheckRulesOriginOrIdJSONRequestBody defines body for PutApiAlertingCheckRulesOriginOrId for application/json ContentType.

type PutApiAlertingCheckRulesOriginOrIdParams

type PutApiAlertingCheckRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PutApiAlertingCheckRulesOriginOrIdParams defines parameters for PutApiAlertingCheckRulesOriginOrId.

type PutApiAlertingCheckRulesOriginOrIdResponse

type PutApiAlertingCheckRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *PrometheusAlertRule
	JSONDefault  *ErrorResponse
}

func ParsePutApiAlertingCheckRulesOriginOrIdResponse

func ParsePutApiAlertingCheckRulesOriginOrIdResponse(rsp *http.Response) (*PutApiAlertingCheckRulesOriginOrIdResponse, error)

ParsePutApiAlertingCheckRulesOriginOrIdResponse parses an HTTP response from a PutApiAlertingCheckRulesOriginOrIdWithResponse call

func (PutApiAlertingCheckRulesOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (PutApiAlertingCheckRulesOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type PutApiDashboardsOriginOrIdJSONRequestBody

type PutApiDashboardsOriginOrIdJSONRequestBody = DashboardDefinition

PutApiDashboardsOriginOrIdJSONRequestBody defines body for PutApiDashboardsOriginOrId for application/json ContentType.

type PutApiDashboardsOriginOrIdParams

type PutApiDashboardsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PutApiDashboardsOriginOrIdParams defines parameters for PutApiDashboardsOriginOrId.

type PutApiDashboardsOriginOrIdResponse

type PutApiDashboardsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *DashboardDefinition
	JSONDefault  *ErrorResponse
}

func ParsePutApiDashboardsOriginOrIdResponse

func ParsePutApiDashboardsOriginOrIdResponse(rsp *http.Response) (*PutApiDashboardsOriginOrIdResponse, error)

ParsePutApiDashboardsOriginOrIdResponse parses an HTTP response from a PutApiDashboardsOriginOrIdWithResponse call

func (PutApiDashboardsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (PutApiDashboardsOriginOrIdResponse) StatusCode

func (r PutApiDashboardsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody added in v1.6.0

type PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody = RecordingRuleGroupUpdateRequest

PutApiRecordingRuleGroupsOriginOrIdJSONRequestBody defines body for PutApiRecordingRuleGroupsOriginOrId for application/json ContentType.

type PutApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

type PutApiRecordingRuleGroupsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *RecordingRuleGroupResponse
	JSONDefault  *ErrorResponse
}

func ParsePutApiRecordingRuleGroupsOriginOrIdResponse added in v1.6.0

func ParsePutApiRecordingRuleGroupsOriginOrIdResponse(rsp *http.Response) (*PutApiRecordingRuleGroupsOriginOrIdResponse, error)

ParsePutApiRecordingRuleGroupsOriginOrIdResponse parses an HTTP response from a PutApiRecordingRuleGroupsOriginOrIdWithResponse call

func (PutApiRecordingRuleGroupsOriginOrIdResponse) Status added in v1.6.0

Status returns HTTPResponse.Status

func (PutApiRecordingRuleGroupsOriginOrIdResponse) StatusCode added in v1.6.0

StatusCode returns HTTPResponse.StatusCode

type PutApiSamplingRulesOriginOrIdJSONRequestBody added in v1.1.0

type PutApiSamplingRulesOriginOrIdJSONRequestBody = SamplingRuleResponse

PutApiSamplingRulesOriginOrIdJSONRequestBody defines body for PutApiSamplingRulesOriginOrId for application/json ContentType.

type PutApiSamplingRulesOriginOrIdParams added in v1.1.0

type PutApiSamplingRulesOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PutApiSamplingRulesOriginOrIdParams defines parameters for PutApiSamplingRulesOriginOrId.

type PutApiSamplingRulesOriginOrIdResponse added in v1.1.0

type PutApiSamplingRulesOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SamplingRuleResponse
	JSON403      *ErrorResponse
	JSONDefault  *ErrorResponse
}

func ParsePutApiSamplingRulesOriginOrIdResponse added in v1.1.0

func ParsePutApiSamplingRulesOriginOrIdResponse(rsp *http.Response) (*PutApiSamplingRulesOriginOrIdResponse, error)

ParsePutApiSamplingRulesOriginOrIdResponse parses an HTTP response from a PutApiSamplingRulesOriginOrIdWithResponse call

func (PutApiSamplingRulesOriginOrIdResponse) Status added in v1.1.0

Status returns HTTPResponse.Status

func (PutApiSamplingRulesOriginOrIdResponse) StatusCode added in v1.1.0

StatusCode returns HTTPResponse.StatusCode

type PutApiSyntheticChecksOriginOrIdJSONRequestBody

type PutApiSyntheticChecksOriginOrIdJSONRequestBody = SyntheticCheckDefinition

PutApiSyntheticChecksOriginOrIdJSONRequestBody defines body for PutApiSyntheticChecksOriginOrId for application/json ContentType.

type PutApiSyntheticChecksOriginOrIdParams

type PutApiSyntheticChecksOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PutApiSyntheticChecksOriginOrIdParams defines parameters for PutApiSyntheticChecksOriginOrId.

type PutApiSyntheticChecksOriginOrIdResponse

type PutApiSyntheticChecksOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *SyntheticCheckDefinition
	JSONDefault  *ErrorResponse
}

func ParsePutApiSyntheticChecksOriginOrIdResponse

func ParsePutApiSyntheticChecksOriginOrIdResponse(rsp *http.Response) (*PutApiSyntheticChecksOriginOrIdResponse, error)

ParsePutApiSyntheticChecksOriginOrIdResponse parses an HTTP response from a PutApiSyntheticChecksOriginOrIdWithResponse call

func (PutApiSyntheticChecksOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (PutApiSyntheticChecksOriginOrIdResponse) StatusCode

StatusCode returns HTTPResponse.StatusCode

type PutApiTeamsOriginOrIdDisplayJSONRequestBody added in v1.4.0

type PutApiTeamsOriginOrIdDisplayJSONRequestBody = TeamDisplay

PutApiTeamsOriginOrIdDisplayJSONRequestBody defines body for PutApiTeamsOriginOrIdDisplay for application/json ContentType.

type PutApiTeamsOriginOrIdDisplayResponse added in v1.4.0

type PutApiTeamsOriginOrIdDisplayResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSONDefault  *ErrorResponse
}

func ParsePutApiTeamsOriginOrIdDisplayResponse added in v1.4.0

func ParsePutApiTeamsOriginOrIdDisplayResponse(rsp *http.Response) (*PutApiTeamsOriginOrIdDisplayResponse, error)

ParsePutApiTeamsOriginOrIdDisplayResponse parses an HTTP response from a PutApiTeamsOriginOrIdDisplayWithResponse call

func (PutApiTeamsOriginOrIdDisplayResponse) Status added in v1.4.0

Status returns HTTPResponse.Status

func (PutApiTeamsOriginOrIdDisplayResponse) StatusCode added in v1.4.0

StatusCode returns HTTPResponse.StatusCode

type PutApiViewsOriginOrIdJSONRequestBody

type PutApiViewsOriginOrIdJSONRequestBody = ViewDefinition

PutApiViewsOriginOrIdJSONRequestBody defines body for PutApiViewsOriginOrId for application/json ContentType.

type PutApiViewsOriginOrIdParams

type PutApiViewsOriginOrIdParams struct {
	Dataset *Dataset `form:"dataset,omitempty" json:"dataset,omitempty"`
}

PutApiViewsOriginOrIdParams defines parameters for PutApiViewsOriginOrId.

type PutApiViewsOriginOrIdResponse

type PutApiViewsOriginOrIdResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *ViewDefinition
	JSONDefault  *ErrorResponse
}

func ParsePutApiViewsOriginOrIdResponse

func ParsePutApiViewsOriginOrIdResponse(rsp *http.Response) (*PutApiViewsOriginOrIdResponse, error)

ParsePutApiViewsOriginOrIdResponse parses an HTTP response from a PutApiViewsOriginOrIdWithResponse call

func (PutApiViewsOriginOrIdResponse) Status

Status returns HTTPResponse.Status

func (PutApiViewsOriginOrIdResponse) StatusCode

func (r PutApiViewsOriginOrIdResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type RecordingRule added in v1.6.0

type RecordingRule struct {
	// Expression PromQL expression to evaluate. The result is stored under the metric name defined by 'record'.
	Expression string `json:"expression"`

	// Labels Additional labels to add to recorded metrics
	Labels *map[string]string `json:"labels,omitempty"`

	// Record Name of the output metric. Must be a valid Prometheus metric name.
	Record string `json:"record"`
}

RecordingRule An individual recording rule that pre-computes a PromQL expression and stores the result as a new metric. Follows the Prometheus recording rule format (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/).

type RecordingRuleGroupAction added in v1.6.0

type RecordingRuleGroupAction string

RecordingRuleGroupAction defines model for RecordingRuleGroupAction.

const (
	RecordingRuleGroupDelete RecordingRuleGroupAction = "recording_rule_group:delete"
	RecordingRuleGroupRead   RecordingRuleGroupAction = "recording_rule_group:read"
	RecordingRuleGroupWrite  RecordingRuleGroupAction = "recording_rule_group:write"
)

Defines values for RecordingRuleGroupAction.

type RecordingRuleGroupAnnotations added in v1.6.0

type RecordingRuleGroupAnnotations struct {
	// Dash0ComcreatedAt Timestamp when the group was created. Set by the server; read-only.
	Dash0ComcreatedAt *time.Time `json:"dash0.com/created-at,omitempty"`

	// Dash0ComdeletedAt Soft-delete timestamp. Present when the group has been deleted but not yet purged. Set by the server; read-only.
	Dash0ComdeletedAt *time.Time `json:"dash0.com/deleted-at,omitempty"`

	// Dash0ComfolderPath Optional UI folder path for organising groups (e.g. '/infrastructure/hosts'). Nesting is expressed with '/' separators.
	Dash0ComfolderPath *string `json:"dash0.com/folder-path,omitempty"`

	// Dash0Comsharing Comma-separated list of principals to grant read access to for API-managed resources. Supported formats: 'team:<team_id>' and 'user:<email>'. Example: 'team:team_01abc,user:alice@example.com'.
	Dash0Comsharing *string `json:"dash0.com/sharing,omitempty"`

	// Dash0ComupdatedAt Timestamp of the last update. Set by the server; read-only.
	Dash0ComupdatedAt *time.Time `json:"dash0.com/updated-at,omitempty"`
}

RecordingRuleGroupAnnotations defines model for RecordingRuleGroupAnnotations.

type RecordingRuleGroupCreateRequest added in v1.6.0

type RecordingRuleGroupCreateRequest = RecordingRuleGroupDefinition

RecordingRuleGroupCreateRequest A group of recording rules evaluated together at a common interval. Follows the Prometheus recording rule group concept (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) with Dash0-specific extensions for access control, dataset scoping, and UI organization.

type RecordingRuleGroupDefinition added in v1.6.0

type RecordingRuleGroupDefinition struct {
	Kind     RecordingRuleGroupDefinitionKind `json:"kind"`
	Metadata RecordingRuleGroupMetadata       `json:"metadata"`
	Spec     RecordingRuleGroupSpec           `json:"spec"`
}

RecordingRuleGroupDefinition A group of recording rules evaluated together at a common interval. Follows the Prometheus recording rule group concept (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) with Dash0-specific extensions for access control, dataset scoping, and UI organization.

type RecordingRuleGroupDefinitionKind added in v1.6.0

type RecordingRuleGroupDefinitionKind string

RecordingRuleGroupDefinitionKind defines model for RecordingRuleGroupDefinition.Kind.

const (
	Dash0RecordingRuleGroup RecordingRuleGroupDefinitionKind = "Dash0RecordingRuleGroup"
)

Defines values for RecordingRuleGroupDefinitionKind.

type RecordingRuleGroupDisplay added in v1.6.0

type RecordingRuleGroupDisplay struct {
	// Name Short-form name for UI display
	Name string `json:"name"`
}

RecordingRuleGroupDisplay defines model for RecordingRuleGroupDisplay.

type RecordingRuleGroupLabels added in v1.6.0

type RecordingRuleGroupLabels struct {
	// Dash0Comdataset Dataset this group belongs to. Defaults to the default dataset when absent.
	Dash0Comdataset *string `json:"dash0.com/dataset,omitempty"`

	// Dash0Comid Unique internal ID of the recording rule group. Set by the server on creation; do not set manually.
	Dash0Comid *string `json:"dash0.com/id,omitempty"`

	// Dash0Comorigin External identifier for API-managed resources (e.g. the CRD name from an operator or Terraform resource ID). Empty for user-created groups; non-empty for groups created via the internal API. Groups with a non-empty origin have write access controlled exclusively through explicit permission entries rather than by the admin role.
	Dash0Comorigin *string `json:"dash0.com/origin,omitempty"`

	// Dash0Comsource Origin of the recording rule group. 'ui' — created interactively in the Dash0 UI. 'terraform' — managed via the Dash0 Terraform provider. 'operator' — managed via the Dash0 Kubernetes operator. 'api' — created directly through the internal API.
	Dash0Comsource *RecordingRuleSource `json:"dash0.com/source,omitempty"`

	// Dash0Comversion Current version of the group. Needs to be set when updating a group to prevent conflicting writes.
	Dash0Comversion *string `json:"dash0.com/version,omitempty"`
}

RecordingRuleGroupLabels defines model for RecordingRuleGroupLabels.

type RecordingRuleGroupListResponse added in v1.6.0

type RecordingRuleGroupListResponse struct {
	RecordingRuleGroups []RecordingRuleGroupResponse `json:"recordingRuleGroups"`
}

RecordingRuleGroupListResponse defines model for RecordingRuleGroupListResponse.

type RecordingRuleGroupMetadata added in v1.6.0

type RecordingRuleGroupMetadata struct {
	Annotations *RecordingRuleGroupAnnotations `json:"annotations,omitempty"`
	Labels      *RecordingRuleGroupLabels      `json:"labels,omitempty"`

	// Name Group name (e.g., "http_metrics")
	Name string `json:"name"`
}

RecordingRuleGroupMetadata defines model for RecordingRuleGroupMetadata.

type RecordingRuleGroupPermission added in v1.6.0

type RecordingRuleGroupPermission struct {
	// Actions Actions granted to this principal on the recording rule group.
	Actions []RecordingRuleGroupAction `json:"actions"`

	// Role organization role (e.g. 'admin'). Role-based entries are managed implicitly by the server and are not included in write requests.
	Role *string `json:"role,omitempty"`

	// TeamId Internal team ID. The granted actions apply to all members of this team.
	TeamId *string `json:"teamId,omitempty"`

	// UserId Internal user ID (UUID). The granted actions apply to this specific user.
	UserId *string `json:"userId,omitempty"`
}

RecordingRuleGroupPermission An access control entry granting a set of actions to a single principal. Exactly one of teamId, userId, or role should be set.

type RecordingRuleGroupResponse added in v1.6.0

type RecordingRuleGroupResponse = RecordingRuleGroupDefinition

RecordingRuleGroupResponse A group of recording rules evaluated together at a common interval. Follows the Prometheus recording rule group concept (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) with Dash0-specific extensions for access control, dataset scoping, and UI organization.

type RecordingRuleGroupSpec added in v1.6.0

type RecordingRuleGroupSpec struct {
	Display RecordingRuleGroupDisplay `json:"display"`

	// Enabled Whether the group's rules are actively evaluated.
	Enabled  bool     `json:"enabled"`
	Interval Duration `json:"interval"`

	// Permissions Access control entries for this group. Each entry grants a set of actions to a specific user, team, or role. Returned with every group response. Include in PUT requests to replace the permission set; absent or empty leaves existing permissions unchanged.
	Permissions *[]RecordingRuleGroupPermission `json:"permissions,omitempty"`

	// PermittedActions Computed, read-only. The set of actions the requesting user is permitted to perform on this group, derived from their role, team memberships, and explicit permission entries.
	PermittedActions *[]RecordingRuleGroupAction `json:"permittedActions,omitempty"`

	// Rules List of recording rules in this group.
	Rules []RecordingRule `json:"rules"`
}

RecordingRuleGroupSpec defines model for RecordingRuleGroupSpec.

type RecordingRuleGroupUpdateRequest added in v1.6.0

type RecordingRuleGroupUpdateRequest = RecordingRuleGroupDefinition

RecordingRuleGroupUpdateRequest A group of recording rules evaluated together at a common interval. Follows the Prometheus recording rule group concept (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) with Dash0-specific extensions for access control, dataset scoping, and UI organization.

type RecordingRuleSource added in v1.6.0

type RecordingRuleSource string

RecordingRuleSource Origin of the recording rule group. 'ui' — created interactively in the Dash0 UI. 'terraform' — managed via the Dash0 Terraform provider. 'operator' — managed via the Dash0 Kubernetes operator. 'api' — created directly through the internal API.

const (
	RecordingRuleSourceApi       RecordingRuleSource = "api"
	RecordingRuleSourceOperator  RecordingRuleSource = "operator"
	RecordingRuleSourceTerraform RecordingRuleSource = "terraform"
	RecordingRuleSourceUi        RecordingRuleSource = "ui"
)

Defines values for RecordingRuleSource.

type RelativeTime

type RelativeTime = string

RelativeTime A relative time reference based on the current time ("now").

**Format**: `now[+/-duration]`

**Examples**: - `now` - current time - `now-30m` - 30 minutes ago - `now-1h` - 1 hour ago - `now-1d` - 1 day ago

**Duration Units**: - `s` - seconds - `m` - minutes - `h` - hours - `d` - days - `w` - weeks - `M` - months

type RequestEditorFn

type RequestEditorFn func(ctx context.Context, req *http.Request) error

RequestEditorFn is the function signature for the RequestEditor callback function

type Resource

type Resource struct {
	Attributes             []KeyValue                      `json:"attributes"`
	Clouds                 *ResourceClouds                 `json:"clouds,omitempty"`
	DeploymentEnvironments *ResourceDeploymentEnvironments `json:"deploymentEnvironments,omitempty"`
	DroppedAttributesCount *int64                          `json:"droppedAttributesCount,omitempty"`

	// FirstSeenUnixNano The property is only included when `includeOTLPSchemaExtensions` is `true`.
	FirstSeenUnixNano *string            `json:"firstSeenUnixNano,omitempty"`
	Languages         *ResourceLanguages `json:"languages,omitempty"`

	// LastSeenUnixNano The property is only included when `includeOTLPSchemaExtensions` is `true`.
	LastSeenUnixNano *string `json:"lastSeenUnixNano,omitempty"`

	// OperationTypes The property is only included when `includeOTLPSchemaExtensions` is `true`.
	OperationTypes *[]string               `json:"operationTypes,omitempty"`
	Orchestrations *ResourceOrchestrations `json:"orchestrations,omitempty"`
}

Resource defines model for Resource.

type ResourceCloud

type ResourceCloud = string

ResourceCloud Resource cloud identified based on the `cloud.provider` resource attribute. Some sample values: - alibaba_cloud - aws - azure - gcp - heroku - ibm_cloud - tencent_cloud

type ResourceClouds

type ResourceClouds = []ResourceCloud

ResourceClouds defines model for ResourceClouds.

type ResourceDeploymentEnvironment

type ResourceDeploymentEnvironment = string

ResourceDeploymentEnvironment The value of the `deployment.environment.name` (or `deployment.environment` pre v1.27 semconvs)

type ResourceDeploymentEnvironments

type ResourceDeploymentEnvironments = []ResourceDeploymentEnvironment

ResourceDeploymentEnvironments defines model for ResourceDeploymentEnvironments.

type ResourceLanguage

type ResourceLanguage = string

ResourceLanguage Resource language identified based on the `telemetry.sdk.language` resource attribute. Some sample values: - cpp - dotnet - erlang - go - java - nodejs - php - python - ruby - rust - swift - webjs

type ResourceLanguages

type ResourceLanguages = []ResourceLanguage

ResourceLanguages defines model for ResourceLanguages.

type ResourceLogs

type ResourceLogs struct {
	Resource  Resource    `json:"resource"`
	SchemaUrl *string     `json:"schemaUrl,omitempty"`
	ScopeLogs []ScopeLogs `json:"scopeLogs"`
}

ResourceLogs defines model for ResourceLogs.

type ResourceOrchestration

type ResourceOrchestration string

ResourceOrchestration Resource orchestration identified based on orchestration related resource attributes, e.g., existence of `k8s.*` resource attribute.

const (
	Kubernetes ResourceOrchestration = "kubernetes"
)

Defines values for ResourceOrchestration.

type ResourceOrchestrations

type ResourceOrchestrations = []ResourceOrchestration

ResourceOrchestrations defines model for ResourceOrchestrations.

type ResourceSpans

type ResourceSpans struct {
	Resource   Resource     `json:"resource"`
	SchemaUrl  *string      `json:"schemaUrl,omitempty"`
	ScopeSpans []ScopeSpans `json:"scopeSpans"`
}

ResourceSpans defines model for ResourceSpans.

type ResultRow added in v1.6.0

type ResultRow struct {
	Values []KeyValue `json:"values"`
}

ResultRow defines model for ResultRow.

type ResultRows added in v1.6.0

type ResultRows = []ResultRow

ResultRows defines model for ResultRows.

type Sampling

type Sampling struct {
	Mode SamplingMode `json:"mode"`

	// TimeRange A range of time between two time references.
	TimeRange TimeReferenceRange `json:"timeRange"`
}

Sampling defines model for Sampling.

type SamplingCondition added in v1.1.0

type SamplingCondition struct {
	// contains filtered or unexported fields
}

SamplingCondition defines model for SamplingCondition.

func (SamplingCondition) AsSamplingConditionAnd added in v1.1.0

func (t SamplingCondition) AsSamplingConditionAnd() (SamplingConditionAnd, error)

AsSamplingConditionAnd returns the union data inside the SamplingCondition as a SamplingConditionAnd

func (SamplingCondition) AsSamplingConditionError added in v1.1.0

func (t SamplingCondition) AsSamplingConditionError() (SamplingConditionError, error)

AsSamplingConditionError returns the union data inside the SamplingCondition as a SamplingConditionError

func (SamplingCondition) AsSamplingConditionOttl added in v1.1.0

func (t SamplingCondition) AsSamplingConditionOttl() (SamplingConditionOttl, error)

AsSamplingConditionOttl returns the union data inside the SamplingCondition as a SamplingConditionOttl

func (SamplingCondition) AsSamplingConditionProbabilistic added in v1.1.0

func (t SamplingCondition) AsSamplingConditionProbabilistic() (SamplingConditionProbabilistic, error)

AsSamplingConditionProbabilistic returns the union data inside the SamplingCondition as a SamplingConditionProbabilistic

func (*SamplingCondition) FromSamplingConditionAnd added in v1.1.0

func (t *SamplingCondition) FromSamplingConditionAnd(v SamplingConditionAnd) error

FromSamplingConditionAnd overwrites any union data inside the SamplingCondition as the provided SamplingConditionAnd

func (*SamplingCondition) FromSamplingConditionError added in v1.1.0

func (t *SamplingCondition) FromSamplingConditionError(v SamplingConditionError) error

FromSamplingConditionError overwrites any union data inside the SamplingCondition as the provided SamplingConditionError

func (*SamplingCondition) FromSamplingConditionOttl added in v1.1.0

func (t *SamplingCondition) FromSamplingConditionOttl(v SamplingConditionOttl) error

FromSamplingConditionOttl overwrites any union data inside the SamplingCondition as the provided SamplingConditionOttl

func (*SamplingCondition) FromSamplingConditionProbabilistic added in v1.1.0

func (t *SamplingCondition) FromSamplingConditionProbabilistic(v SamplingConditionProbabilistic) error

FromSamplingConditionProbabilistic overwrites any union data inside the SamplingCondition as the provided SamplingConditionProbabilistic

func (SamplingCondition) MarshalJSON added in v1.1.0

func (t SamplingCondition) MarshalJSON() ([]byte, error)

func (*SamplingCondition) MergeSamplingConditionAnd added in v1.1.0

func (t *SamplingCondition) MergeSamplingConditionAnd(v SamplingConditionAnd) error

MergeSamplingConditionAnd performs a merge with any union data inside the SamplingCondition, using the provided SamplingConditionAnd

func (*SamplingCondition) MergeSamplingConditionError added in v1.1.0

func (t *SamplingCondition) MergeSamplingConditionError(v SamplingConditionError) error

MergeSamplingConditionError performs a merge with any union data inside the SamplingCondition, using the provided SamplingConditionError

func (*SamplingCondition) MergeSamplingConditionOttl added in v1.1.0

func (t *SamplingCondition) MergeSamplingConditionOttl(v SamplingConditionOttl) error

MergeSamplingConditionOttl performs a merge with any union data inside the SamplingCondition, using the provided SamplingConditionOttl

func (*SamplingCondition) MergeSamplingConditionProbabilistic added in v1.1.0

func (t *SamplingCondition) MergeSamplingConditionProbabilistic(v SamplingConditionProbabilistic) error

MergeSamplingConditionProbabilistic performs a merge with any union data inside the SamplingCondition, using the provided SamplingConditionProbabilistic

func (*SamplingCondition) UnmarshalJSON added in v1.1.0

func (t *SamplingCondition) UnmarshalJSON(b []byte) error

type SamplingConditionAnd added in v1.1.0

type SamplingConditionAnd struct {
	Kind SamplingConditionAndKind `json:"kind"`
	Spec SamplingConditionAndSpec `json:"spec"`
}

SamplingConditionAnd defines model for SamplingConditionAnd.

type SamplingConditionAndKind added in v1.1.0

type SamplingConditionAndKind string

SamplingConditionAndKind defines model for SamplingConditionAnd.Kind.

const (
	And SamplingConditionAndKind = "and"
)

Defines values for SamplingConditionAndKind.

type SamplingConditionAndSpec added in v1.1.0

type SamplingConditionAndSpec struct {
	Conditions []SamplingCondition `json:"conditions"`
}

SamplingConditionAndSpec defines model for SamplingConditionAndSpec.

type SamplingConditionError added in v1.1.0

type SamplingConditionError struct {
	Kind SamplingConditionErrorKind `json:"kind"`
	Spec SamplingConditionErrorSpec `json:"spec"`
}

SamplingConditionError Matches spans that have the have `otel.span.status.code=ERROR`

type SamplingConditionErrorKind added in v1.1.0

type SamplingConditionErrorKind string

SamplingConditionErrorKind defines model for SamplingConditionError.Kind.

const (
	SamplingConditionErrorKindError SamplingConditionErrorKind = "error"
)

Defines values for SamplingConditionErrorKind.

type SamplingConditionErrorSpec added in v1.1.0

type SamplingConditionErrorSpec = interface{}

SamplingConditionErrorSpec defines model for SamplingConditionErrorSpec.

type SamplingConditionOttl added in v1.1.0

type SamplingConditionOttl struct {
	Kind SamplingConditionOttlKind `json:"kind"`
	Spec SamplingConditionOttlSpec `json:"spec"`
}

SamplingConditionOttl defines model for SamplingConditionOttl.

type SamplingConditionOttlKind added in v1.1.0

type SamplingConditionOttlKind string

SamplingConditionOttlKind defines model for SamplingConditionOttl.Kind.

const (
	Ottl SamplingConditionOttlKind = "ottl"
)

Defines values for SamplingConditionOttlKind.

type SamplingConditionOttlSpec added in v1.1.0

type SamplingConditionOttlSpec struct {
	Ottl string `json:"ottl"`
}

SamplingConditionOttlSpec defines model for SamplingConditionOttlSpec.

type SamplingConditionProbabilistic added in v1.1.0

type SamplingConditionProbabilistic struct {
	Kind SamplingConditionProbabilisticKind `json:"kind"`
	Spec SamplingConditionProbabilisticSpec `json:"spec"`
}

SamplingConditionProbabilistic defines model for SamplingConditionProbabilistic.

type SamplingConditionProbabilisticKind added in v1.1.0

type SamplingConditionProbabilisticKind string

SamplingConditionProbabilisticKind defines model for SamplingConditionProbabilistic.Kind.

const (
	Probabilistic SamplingConditionProbabilisticKind = "probabilistic"
)

Defines values for SamplingConditionProbabilisticKind.

type SamplingConditionProbabilisticSpec added in v1.1.0

type SamplingConditionProbabilisticSpec struct {
	// Rate A value between 0 and 1 reflecting the percentage of traces that should be sampled probabilistically.
	// This sampling decision is made deterministically by inspecting the trace ID.
	Rate float32 `json:"rate"`
}

SamplingConditionProbabilisticSpec defines model for SamplingConditionProbabilisticSpec.

type SamplingDefinition added in v1.1.0

type SamplingDefinition struct {
	Kind     SamplingDefinitionKind `json:"kind"`
	Metadata SamplingMetadata       `json:"metadata"`
	Spec     SamplingSpec           `json:"spec"`
}

SamplingDefinition defines model for SamplingDefinition.

type SamplingDefinitionKind added in v1.1.0

type SamplingDefinitionKind string

SamplingDefinitionKind defines model for SamplingDefinition.Kind.

const (
	Dash0Sampling SamplingDefinitionKind = "Dash0Sampling"
)

Defines values for SamplingDefinitionKind.

type SamplingDisplay added in v1.1.0

type SamplingDisplay struct {
	// Name Short-form name for the view to be shown prominently within the view list and atop
	// the screen when the view is selected.
	Name string `json:"name"`
}

SamplingDisplay defines model for SamplingDisplay.

type SamplingLabels added in v1.1.0

type SamplingLabels struct {
	Custom          *map[string]string `json:"custom,omitempty"`
	Dash0Comdataset *string            `json:"dash0.com/dataset,omitempty"`
	Dash0Comid      *string            `json:"dash0.com/id,omitempty"`
	Dash0Comorigin  *string            `json:"dash0.com/origin,omitempty"`
	Dash0Comversion *string            `json:"dash0.com/version,omitempty"`
}

SamplingLabels defines model for SamplingLabels.

type SamplingMetadata added in v1.1.0

type SamplingMetadata struct {
	Labels *SamplingLabels `json:"labels,omitempty"`
	Name   string          `json:"name"`
}

SamplingMetadata defines model for SamplingMetadata.

type SamplingMode

type SamplingMode string

SamplingMode defines model for SamplingMode.

const (
	SamplingModeAdaptive SamplingMode = "adaptive"
	SamplingModeDisabled SamplingMode = "disabled"
)

Defines values for SamplingMode.

type SamplingRateLimit added in v1.1.0

type SamplingRateLimit struct {
	// Rate The maximum number of traces per minute that should be allowed for this sampling rule. Dash0 will make every
	// effort not to exceed this rate. However, there is also no guarantee that Dash0 will match exactly this rate.
	// Dash0 is attempting to hit a rate that is lower than or equal to the configured rate.
	//
	// Dash0 cannot guarantee that very low rate limits (<=16) are upheld.
	Rate int `json:"rate"`
}

SamplingRateLimit Rate limit is helpful to avoid ingesting extremely large amounts of spans when the sampling conditions are triggering much more frequently than expected. For example, when the tail sampling rule is configured to match every error, then a system-wide outage can result in a huge amount of spans being ingested.

Note: Probabilistic-only sampling rules do not support rate limiting.

type SamplingRuleCreateRequest added in v1.1.0

type SamplingRuleCreateRequest = SamplingDefinition

SamplingRuleCreateRequest defines model for SamplingRuleCreateRequest.

type SamplingRuleResponse added in v1.1.0

type SamplingRuleResponse = SamplingDefinition

SamplingRuleResponse defines model for SamplingRuleResponse.

type SamplingSpec added in v1.1.0

type SamplingSpec struct {
	Conditions SamplingCondition `json:"conditions"`
	Display    *SamplingDisplay  `json:"display,omitempty"`
	Enabled    bool              `json:"enabled"`

	// RateLimit Rate limit is helpful to avoid ingesting extremely large amounts of spans when the sampling conditions are
	// triggering much more frequently than expected. For example, when the tail sampling rule is configured to match
	// every error, then a system-wide outage can result in a huge amount of spans being ingested.
	//
	// Note: Probabilistic-only sampling rules do not support rate limiting.
	RateLimit *SamplingRateLimit `json:"rateLimit,omitempty"`
}

SamplingSpec defines model for SamplingSpec.

type ScopeLogs

type ScopeLogs struct {
	LogRecords []LogRecord `json:"logRecords"`
	SchemaUrl  *string     `json:"schemaUrl,omitempty"`

	// Scope InstrumentationScope is a message representing the instrumentation scope information such as the fully qualified name and version.
	Scope *InstrumentationScope `json:"scope,omitempty"`
}

ScopeLogs defines model for ScopeLogs.

type ScopeSpans

type ScopeSpans struct {
	SchemaUrl *string `json:"schemaUrl,omitempty"`

	// Scope InstrumentationScope is a message representing the instrumentation scope information such as the fully qualified name and version.
	Scope *InstrumentationScope `json:"scope,omitempty"`
	Spans []Span                `json:"spans"`
}

ScopeSpans defines model for ScopeSpans.

type SeverityNumber

type SeverityNumber = int32

SeverityNumber SEVERITY_NUMBER_UNSPECIFIED = 0; SEVERITY_NUMBER_TRACE = 1; SEVERITY_NUMBER_TRACE2 = 2; SEVERITY_NUMBER_TRACE3 = 3; SEVERITY_NUMBER_TRACE4 = 4; SEVERITY_NUMBER_DEBUG = 5; SEVERITY_NUMBER_DEBUG2 = 6; SEVERITY_NUMBER_DEBUG3 = 7; SEVERITY_NUMBER_DEBUG4 = 8; SEVERITY_NUMBER_INFO = 9; SEVERITY_NUMBER_INFO2 = 10; SEVERITY_NUMBER_INFO3 = 11; SEVERITY_NUMBER_INFO4 = 12; SEVERITY_NUMBER_WARN = 13; SEVERITY_NUMBER_WARN2 = 14; SEVERITY_NUMBER_WARN3 = 15; SEVERITY_NUMBER_WARN4 = 16; SEVERITY_NUMBER_ERROR = 17; SEVERITY_NUMBER_ERROR2 = 18; SEVERITY_NUMBER_ERROR3 = 19; SEVERITY_NUMBER_ERROR4 = 20; SEVERITY_NUMBER_FATAL = 21; SEVERITY_NUMBER_FATAL2 = 22; SEVERITY_NUMBER_FATAL3 = 23; SEVERITY_NUMBER_FATAL4 = 24;

type Span

type Span struct {
	Attributes []KeyValue `json:"attributes"`

	// Dash0ForwardLinks Forward links pointing to spans in other traces.
	// The property is only included when `includeOTLPSchemaExtensions` is `true`.
	Dash0ForwardLinks *[]SpanLink `json:"dash0ForwardLinks,omitempty"`

	// Dash0Name The property is only included when `includeOTLPSchemaExtensions` is `true`.
	Dash0Name *string `json:"dash0Name,omitempty"`

	// Dash0TraceOriginParentSpanId The property is only included when `includeOTLPSchemaExtensions` is `true`.
	Dash0TraceOriginParentSpanId *[]byte `json:"dash0TraceOriginParentSpanId,omitempty"`

	// Dash0TraceOriginType The property is only included when `includeOTLPSchemaExtensions` is `true`.
	Dash0TraceOriginType   *string     `json:"dash0TraceOriginType,omitempty"`
	DroppedAttributesCount *int64      `json:"droppedAttributesCount,omitempty"`
	DroppedEventsCount     *int64      `json:"droppedEventsCount,omitempty"`
	DroppedLinksCount      *int64      `json:"droppedLinksCount,omitempty"`
	EndTimeUnixNano        string      `json:"endTimeUnixNano"`
	Events                 []SpanEvent `json:"events"`
	Flags                  *int64      `json:"flags,omitempty"`

	// HasChildren The property is only included when `includeOTLPSchemaExtensions` is `true`.
	HasChildren *bool `json:"hasChildren,omitempty"`

	// Kind // Unspecified. Do NOT use as default.
	// // Implementations MAY assume SpanKind to be INTERNAL when receiving UNSPECIFIED.
	// SPAN_KIND_UNSPECIFIED = 0;
	//
	// // Indicates that the span represents an internal operation within an application,
	// // as opposed to an operation happening at the boundaries. Default value.
	// SPAN_KIND_INTERNAL = 1;
	//
	// // Indicates that the span covers server-side handling of an RPC or other
	// // remote network request.
	// SPAN_KIND_SERVER = 2;
	//
	// // Indicates that the span describes a request to some remote service.
	// SPAN_KIND_CLIENT = 3;
	//
	// // Indicates that the span describes a producer sending a message to a broker.
	// // Unlike CLIENT and SERVER, there is often no direct critical path latency relationship
	// // between producer and consumer spans. A PRODUCER span ends when the message was accepted
	// // by the broker while the logical processing of the message might span a much longer time.
	// SPAN_KIND_PRODUCER = 4;
	//
	// // Indicates that the span describes consumer receiving a message from a broker.
	// // Like the PRODUCER kind, there is often no direct critical path latency relationship
	// // between producer and consumer spans.
	// SPAN_KIND_CONSUMER = 5;
	Kind              SpanKind   `json:"kind"`
	Links             []SpanLink `json:"links"`
	Name              string     `json:"name"`
	ParentSpanId      *[]byte    `json:"parentSpanId,omitempty"`
	SpanId            []byte     `json:"spanId"`
	StartTimeUnixNano string     `json:"startTimeUnixNano"`
	Status            SpanStatus `json:"status"`
	TraceId           []byte     `json:"traceId"`
	TraceState        *string    `json:"traceState,omitempty"`
}

Span defines model for Span.

type SpanEvent

type SpanEvent struct {
	Attributes             []KeyValue `json:"attributes"`
	DroppedAttributesCount *int64     `json:"droppedAttributesCount,omitempty"`
	Name                   string     `json:"name"`
	TimeUnixNano           string     `json:"timeUnixNano"`
}

SpanEvent defines model for SpanEvent.

type SpanKind

type SpanKind = int32

SpanKind // Unspecified. Do NOT use as default. // Implementations MAY assume SpanKind to be INTERNAL when receiving UNSPECIFIED. SPAN_KIND_UNSPECIFIED = 0;

// Indicates that the span represents an internal operation within an application, // as opposed to an operation happening at the boundaries. Default value. SPAN_KIND_INTERNAL = 1;

// Indicates that the span covers server-side handling of an RPC or other // remote network request. SPAN_KIND_SERVER = 2;

// Indicates that the span describes a request to some remote service. SPAN_KIND_CLIENT = 3;

// Indicates that the span describes a producer sending a message to a broker. // Unlike CLIENT and SERVER, there is often no direct critical path latency relationship // between producer and consumer spans. A PRODUCER span ends when the message was accepted // by the broker while the logical processing of the message might span a much longer time. SPAN_KIND_PRODUCER = 4;

// Indicates that the span describes consumer receiving a message from a broker. // Like the PRODUCER kind, there is often no direct critical path latency relationship // between producer and consumer spans. SPAN_KIND_CONSUMER = 5;

type SpanLink struct {
	Attributes             []KeyValue `json:"attributes"`
	DroppedAttributesCount *int64     `json:"droppedAttributesCount,omitempty"`
	Flags                  *int64     `json:"flags,omitempty"`
	SpanId                 []byte     `json:"spanId"`
	TraceId                []byte     `json:"traceId"`
	TraceState             *string    `json:"traceState,omitempty"`
}

SpanLink defines model for SpanLink.

type SpanStatus

type SpanStatus struct {
	// Code // The default status.
	// STATUS_CODE_UNSET               = 0;
	// // The Span has been validated by an Application developer or Operator to
	// // have completed successfully.
	// STATUS_CODE_OK                  = 1;
	// // The Span contains an error.
	// STATUS_CODE_ERROR               = 2;
	Code SpanStatusCode `json:"code"`

	// Message A developer-facing human readable error message.
	Message *string `json:"message,omitempty"`
}

SpanStatus defines model for SpanStatus.

type SpanStatusCode

type SpanStatusCode = int32

SpanStatusCode // The default status. STATUS_CODE_UNSET = 0; // The Span has been validated by an Application developer or Operator to // have completed successfully. STATUS_CODE_OK = 1; // The Span contains an error. STATUS_CODE_ERROR = 2;

type SslCertificateAssertion

type SslCertificateAssertion struct {
	Kind SslCertificateAssertionKind `json:"kind"`
	Spec SslCertificateAssertionSpec `json:"spec"`
}

SslCertificateAssertion defines model for SslCertificateAssertion.

type SslCertificateAssertionKind

type SslCertificateAssertionKind string

SslCertificateAssertionKind defines model for SslCertificateAssertion.Kind.

const (
	SslCertificate SslCertificateAssertionKind = "ssl_certificate"
)

Defines values for SslCertificateAssertionKind.

type SslCertificateAssertionSpec

type SslCertificateAssertionSpec struct {
	Value Duration `json:"value"`
}

SslCertificateAssertionSpec defines model for SslCertificateAssertionSpec.

type StringAssertionOperator

type StringAssertionOperator string

StringAssertionOperator defines model for StringAssertionOperator.

const (
	Contains         StringAssertionOperator = "contains"
	DoesNotContain   StringAssertionOperator = "does_not_contain"
	DoesNotEndWith   StringAssertionOperator = "does_not_end_with"
	DoesNotMatch     StringAssertionOperator = "does_not_match"
	DoesNotStartWith StringAssertionOperator = "does_not_start_with"
	EndsWith         StringAssertionOperator = "ends_with"
	Is               StringAssertionOperator = "is"
	IsNot            StringAssertionOperator = "is_not"
	IsNotOneOf       StringAssertionOperator = "is_not_one_of"
	IsNotSet         StringAssertionOperator = "is_not_set"
	IsOneOf          StringAssertionOperator = "is_one_of"
	IsSet            StringAssertionOperator = "is_set"
	Matches          StringAssertionOperator = "matches"
	StartsWith       StringAssertionOperator = "starts_with"
)

Defines values for StringAssertionOperator.

type SyntheticCheckAction

type SyntheticCheckAction string

SyntheticCheckAction defines model for SyntheticCheckAction.

const (
	SyntheticCheckDelete SyntheticCheckAction = "synthetic_check:delete"
	SyntheticCheckRead   SyntheticCheckAction = "synthetic_check:read"
	SyntheticCheckWrite  SyntheticCheckAction = "synthetic_check:write"
)

Defines values for SyntheticCheckAction.

type SyntheticCheckAnnotations

type SyntheticCheckAnnotations struct {
	Dash0ComdeletedAt  *time.Time `json:"dash0.com/deleted-at,omitempty"`
	Dash0ComfolderPath *string    `json:"dash0.com/folder-path,omitempty"`
	Dash0Comsharing    *string    `json:"dash0.com/sharing,omitempty"`
}

SyntheticCheckAnnotations defines model for SyntheticCheckAnnotations.

type SyntheticCheckAttempt added in v1.4.0

type SyntheticCheckAttempt struct {
	// AttemptId (Internal) Unique identifier for the attempt
	AttemptId string `json:"attemptId"`

	// Duration duration in nanoseconds
	Duration int64 `json:"duration"`

	// ErrorMessage Error message of the synthetic check attempt, if any
	ErrorMessage *string                 `json:"errorMessage,omitempty"`
	ErrorType    *SyntheticHttpErrorType `json:"errorType,omitempty"`

	// FailedCriticalAssertions List of critical assertions that failed
	FailedCriticalAssertions []FailedHttpCheckAssertion `json:"failedCriticalAssertions"`

	// FailedDegradedAssertions List of degraded assertions that failed
	FailedDegradedAssertions []FailedHttpCheckAssertion `json:"failedDegradedAssertions"`

	// IsTestRun (Internal) Whether this attempt was triggered as a test run
	IsTestRun bool `json:"isTestRun"`

	// Location A geographic location identifier from which synthetic checks can be executed.
	Location SyntheticCheckLocation `json:"location"`

	// PassedCriticalAssertions List of critical assertions that passed
	PassedCriticalAssertions []HttpCheckAssertion `json:"passedCriticalAssertions"`

	// PassedDegradedAssertions List of degraded assertions that passed
	PassedDegradedAssertions []HttpCheckAssertion `json:"passedDegradedAssertions"`

	// RunId (Internal) Run ID this attempt belongs to
	RunId string `json:"runId"`

	// SpanId (Internal) Span ID associated with this attempt
	SpanId []byte `json:"spanId"`

	// StartTime A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	StartTime FixedTime `json:"startTime"`

	// StatusCode HTTP status code
	StatusCode int `json:"statusCode"`

	// SyntheticCheckId ID of the synthetic check
	SyntheticCheckId string `json:"syntheticCheckId"`

	// SyntheticCheckVersion Version of the synthetic check
	SyntheticCheckVersion string `json:"syntheticCheckVersion"`

	// TraceId (Internal) Trace ID associated with this attempt
	TraceId []byte `json:"traceId"`
}

SyntheticCheckAttempt defines model for SyntheticCheckAttempt.

type SyntheticCheckAttemptDetails added in v1.4.0

type SyntheticCheckAttemptDetails struct {
	// AttemptId (Internal) Unique identifier for the attempt
	AttemptId string `json:"attemptId"`

	// Duration duration in nanoseconds
	Duration int64 `json:"duration"`

	// ErrorMessage Error message of the synthetic check attempt, if any
	ErrorMessage *string                 `json:"errorMessage,omitempty"`
	ErrorType    *SyntheticHttpErrorType `json:"errorType,omitempty"`

	// Events Span events using OTLP SpanEvent format
	Events []SpanEvent `json:"events"`

	// FailedCriticalAssertions List of critical assertions that failed
	FailedCriticalAssertions []FailedHttpCheckAssertion `json:"failedCriticalAssertions"`

	// FailedDegradedAssertions List of degraded assertions that failed
	FailedDegradedAssertions []FailedHttpCheckAssertion `json:"failedDegradedAssertions"`

	// IsTestRun (Internal) Whether this attempt was triggered as a test run
	IsTestRun bool `json:"isTestRun"`

	// Location A geographic location identifier from which synthetic checks can be executed.
	Location SyntheticCheckLocation `json:"location"`

	// PassedCriticalAssertions List of critical assertions that passed
	PassedCriticalAssertions []HttpCheckAssertion `json:"passedCriticalAssertions"`

	// PassedDegradedAssertions List of degraded assertions that passed
	PassedDegradedAssertions []HttpCheckAssertion `json:"passedDegradedAssertions"`

	// RunId (Internal) Run ID this attempt belongs to
	RunId string `json:"runId"`

	// SpanAttributes Span attributes using OTLP KeyValue format
	SpanAttributes []KeyValue `json:"spanAttributes"`

	// SpanId (Internal) Span ID associated with this attempt
	SpanId []byte `json:"spanId"`

	// StartTime A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	StartTime FixedTime `json:"startTime"`

	// StatusCode HTTP status code
	StatusCode int `json:"statusCode"`

	// SyntheticCheckId ID of the synthetic check
	SyntheticCheckId string `json:"syntheticCheckId"`

	// SyntheticCheckVersion Version of the synthetic check
	SyntheticCheckVersion string `json:"syntheticCheckVersion"`

	// TraceId (Internal) Trace ID associated with this attempt
	TraceId []byte `json:"traceId"`
}

SyntheticCheckAttemptDetails defines model for SyntheticCheckAttemptDetails.

type SyntheticCheckDefinition

type SyntheticCheckDefinition struct {
	Kind     SyntheticCheckDefinitionKind `json:"kind"`
	Metadata SyntheticCheckMetadata       `json:"metadata"`
	Spec     SyntheticCheckSpec           `json:"spec"`
}

SyntheticCheckDefinition defines model for SyntheticCheckDefinition.

type SyntheticCheckDefinitionKind

type SyntheticCheckDefinitionKind string

SyntheticCheckDefinitionKind defines model for SyntheticCheckDefinition.Kind.

const (
	Dash0SyntheticCheck SyntheticCheckDefinitionKind = "Dash0SyntheticCheck"
)

Defines values for SyntheticCheckDefinitionKind.

type SyntheticCheckDisplay

type SyntheticCheckDisplay struct {
	// Name Short-form name for the view to be shown prominently within the view list and atop
	// the screen when the view is selected.
	Name string `json:"name"`
}

SyntheticCheckDisplay defines model for SyntheticCheckDisplay.

type SyntheticCheckLabels

type SyntheticCheckLabels struct {
	// Deprecated: this property has been marked as deprecated upstream, but no `x-deprecated-reason` was set
	Custom          *map[string]string `json:"custom,omitempty"`
	Dash0Comdataset *string            `json:"dash0.com/dataset,omitempty"`
	Dash0Comid      *string            `json:"dash0.com/id,omitempty"`
	Dash0Comorigin  *string            `json:"dash0.com/origin,omitempty"`
	Dash0Comversion *string            `json:"dash0.com/version,omitempty"`
}

SyntheticCheckLabels defines model for SyntheticCheckLabels.

type SyntheticCheckLocation added in v1.6.0

type SyntheticCheckLocation = string

SyntheticCheckLocation A geographic location identifier from which synthetic checks can be executed.

type SyntheticCheckMetadata

type SyntheticCheckMetadata struct {
	Annotations *SyntheticCheckAnnotations `json:"annotations,omitempty"`
	Description *string                    `json:"description,omitempty"`
	Labels      *SyntheticCheckLabels      `json:"labels,omitempty"`
	Name        string                     `json:"name"`
}

SyntheticCheckMetadata defines model for SyntheticCheckMetadata.

type SyntheticCheckNotifications

type SyntheticCheckNotifications struct {
	// Channels The channel IDs that notifications should be sent to in case the check is critical or degraded after
	// executing all the retries.
	Channels []openapi_types.UUID `json:"channels"`

	// OnlyCriticalChannels The channel IDs that should only trigger in case synthetic check status reaches critical state.
	OnlyCriticalChannels *[]openapi_types.UUID `json:"onlyCriticalChannels,omitempty"`
}

SyntheticCheckNotifications defines model for SyntheticCheckNotifications.

type SyntheticCheckPermission

type SyntheticCheckPermission struct {
	Actions []SyntheticCheckAction `json:"actions"`
	Role    *string                `json:"role,omitempty"`
	TeamId  *string                `json:"teamId,omitempty"`
	UserId  *string                `json:"userId,omitempty"`
}

SyntheticCheckPermission defines model for SyntheticCheckPermission.

type SyntheticCheckPlugin

type SyntheticCheckPlugin struct {
	// contains filtered or unexported fields
}

SyntheticCheckPlugin defines model for SyntheticCheckPlugin.

func (SyntheticCheckPlugin) AsSyntheticHttpCheckPlugin

func (t SyntheticCheckPlugin) AsSyntheticHttpCheckPlugin() (SyntheticHttpCheckPlugin, error)

AsSyntheticHttpCheckPlugin returns the union data inside the SyntheticCheckPlugin as a SyntheticHttpCheckPlugin

func (*SyntheticCheckPlugin) FromSyntheticHttpCheckPlugin

func (t *SyntheticCheckPlugin) FromSyntheticHttpCheckPlugin(v SyntheticHttpCheckPlugin) error

FromSyntheticHttpCheckPlugin overwrites any union data inside the SyntheticCheckPlugin as the provided SyntheticHttpCheckPlugin

func (SyntheticCheckPlugin) MarshalJSON

func (t SyntheticCheckPlugin) MarshalJSON() ([]byte, error)

func (*SyntheticCheckPlugin) MergeSyntheticHttpCheckPlugin

func (t *SyntheticCheckPlugin) MergeSyntheticHttpCheckPlugin(v SyntheticHttpCheckPlugin) error

MergeSyntheticHttpCheckPlugin performs a merge with any union data inside the SyntheticCheckPlugin, using the provided SyntheticHttpCheckPlugin

func (*SyntheticCheckPlugin) UnmarshalJSON

func (t *SyntheticCheckPlugin) UnmarshalJSON(b []byte) error

type SyntheticCheckRetries

type SyntheticCheckRetries struct {
	// contains filtered or unexported fields
}

SyntheticCheckRetries defines model for SyntheticCheckRetries.

func (SyntheticCheckRetries) AsSyntheticCheckRetriesExponential

func (t SyntheticCheckRetries) AsSyntheticCheckRetriesExponential() (SyntheticCheckRetriesExponential, error)

AsSyntheticCheckRetriesExponential returns the union data inside the SyntheticCheckRetries as a SyntheticCheckRetriesExponential

func (SyntheticCheckRetries) AsSyntheticCheckRetriesFixed

func (t SyntheticCheckRetries) AsSyntheticCheckRetriesFixed() (SyntheticCheckRetriesFixed, error)

AsSyntheticCheckRetriesFixed returns the union data inside the SyntheticCheckRetries as a SyntheticCheckRetriesFixed

func (SyntheticCheckRetries) AsSyntheticCheckRetriesLinear

func (t SyntheticCheckRetries) AsSyntheticCheckRetriesLinear() (SyntheticCheckRetriesLinear, error)

AsSyntheticCheckRetriesLinear returns the union data inside the SyntheticCheckRetries as a SyntheticCheckRetriesLinear

func (SyntheticCheckRetries) AsSyntheticCheckRetriesOff

func (t SyntheticCheckRetries) AsSyntheticCheckRetriesOff() (SyntheticCheckRetriesOff, error)

AsSyntheticCheckRetriesOff returns the union data inside the SyntheticCheckRetries as a SyntheticCheckRetriesOff

func (*SyntheticCheckRetries) FromSyntheticCheckRetriesExponential

func (t *SyntheticCheckRetries) FromSyntheticCheckRetriesExponential(v SyntheticCheckRetriesExponential) error

FromSyntheticCheckRetriesExponential overwrites any union data inside the SyntheticCheckRetries as the provided SyntheticCheckRetriesExponential

func (*SyntheticCheckRetries) FromSyntheticCheckRetriesFixed

func (t *SyntheticCheckRetries) FromSyntheticCheckRetriesFixed(v SyntheticCheckRetriesFixed) error

FromSyntheticCheckRetriesFixed overwrites any union data inside the SyntheticCheckRetries as the provided SyntheticCheckRetriesFixed

func (*SyntheticCheckRetries) FromSyntheticCheckRetriesLinear

func (t *SyntheticCheckRetries) FromSyntheticCheckRetriesLinear(v SyntheticCheckRetriesLinear) error

FromSyntheticCheckRetriesLinear overwrites any union data inside the SyntheticCheckRetries as the provided SyntheticCheckRetriesLinear

func (*SyntheticCheckRetries) FromSyntheticCheckRetriesOff

func (t *SyntheticCheckRetries) FromSyntheticCheckRetriesOff(v SyntheticCheckRetriesOff) error

FromSyntheticCheckRetriesOff overwrites any union data inside the SyntheticCheckRetries as the provided SyntheticCheckRetriesOff

func (SyntheticCheckRetries) MarshalJSON

func (t SyntheticCheckRetries) MarshalJSON() ([]byte, error)

func (*SyntheticCheckRetries) MergeSyntheticCheckRetriesExponential

func (t *SyntheticCheckRetries) MergeSyntheticCheckRetriesExponential(v SyntheticCheckRetriesExponential) error

MergeSyntheticCheckRetriesExponential performs a merge with any union data inside the SyntheticCheckRetries, using the provided SyntheticCheckRetriesExponential

func (*SyntheticCheckRetries) MergeSyntheticCheckRetriesFixed

func (t *SyntheticCheckRetries) MergeSyntheticCheckRetriesFixed(v SyntheticCheckRetriesFixed) error

MergeSyntheticCheckRetriesFixed performs a merge with any union data inside the SyntheticCheckRetries, using the provided SyntheticCheckRetriesFixed

func (*SyntheticCheckRetries) MergeSyntheticCheckRetriesLinear

func (t *SyntheticCheckRetries) MergeSyntheticCheckRetriesLinear(v SyntheticCheckRetriesLinear) error

MergeSyntheticCheckRetriesLinear performs a merge with any union data inside the SyntheticCheckRetries, using the provided SyntheticCheckRetriesLinear

func (*SyntheticCheckRetries) MergeSyntheticCheckRetriesOff

func (t *SyntheticCheckRetries) MergeSyntheticCheckRetriesOff(v SyntheticCheckRetriesOff) error

MergeSyntheticCheckRetriesOff performs a merge with any union data inside the SyntheticCheckRetries, using the provided SyntheticCheckRetriesOff

func (*SyntheticCheckRetries) UnmarshalJSON

func (t *SyntheticCheckRetries) UnmarshalJSON(b []byte) error

type SyntheticCheckRetriesExponential

type SyntheticCheckRetriesExponential struct {
	Kind SyntheticCheckRetriesExponentialKind `json:"kind"`
	Spec SyntheticCheckRetriesExponentialSpec `json:"spec"`
}

SyntheticCheckRetriesExponential defines model for SyntheticCheckRetriesExponential.

type SyntheticCheckRetriesExponentialKind

type SyntheticCheckRetriesExponentialKind string

SyntheticCheckRetriesExponentialKind defines model for SyntheticCheckRetriesExponential.Kind.

const (
	Exponential SyntheticCheckRetriesExponentialKind = "exponential"
)

Defines values for SyntheticCheckRetriesExponentialKind.

type SyntheticCheckRetriesExponentialSpec

type SyntheticCheckRetriesExponentialSpec struct {
	Attempts     int      `json:"attempts"`
	Delay        Duration `json:"delay"`
	MaximumDelay Duration `json:"maximumDelay"`
}

SyntheticCheckRetriesExponentialSpec defines model for SyntheticCheckRetriesExponentialSpec.

type SyntheticCheckRetriesFixed

type SyntheticCheckRetriesFixed struct {
	Kind SyntheticCheckRetriesFixedKind `json:"kind"`
	Spec SyntheticCheckRetriesFixedSpec `json:"spec"`
}

SyntheticCheckRetriesFixed defines model for SyntheticCheckRetriesFixed.

type SyntheticCheckRetriesFixedKind

type SyntheticCheckRetriesFixedKind string

SyntheticCheckRetriesFixedKind defines model for SyntheticCheckRetriesFixed.Kind.

const (
	Fixed SyntheticCheckRetriesFixedKind = "fixed"
)

Defines values for SyntheticCheckRetriesFixedKind.

type SyntheticCheckRetriesFixedSpec

type SyntheticCheckRetriesFixedSpec struct {
	Attempts int      `json:"attempts"`
	Delay    Duration `json:"delay"`
}

SyntheticCheckRetriesFixedSpec defines model for SyntheticCheckRetriesFixedSpec.

type SyntheticCheckRetriesLinear

type SyntheticCheckRetriesLinear struct {
	Kind SyntheticCheckRetriesLinearKind `json:"kind"`
	Spec SyntheticCheckRetriesLinearSpec `json:"spec"`
}

SyntheticCheckRetriesLinear defines model for SyntheticCheckRetriesLinear.

type SyntheticCheckRetriesLinearKind

type SyntheticCheckRetriesLinearKind string

SyntheticCheckRetriesLinearKind defines model for SyntheticCheckRetriesLinear.Kind.

const (
	SyntheticCheckRetriesLinearKindLinear SyntheticCheckRetriesLinearKind = "linear"
)

Defines values for SyntheticCheckRetriesLinearKind.

type SyntheticCheckRetriesLinearSpec

type SyntheticCheckRetriesLinearSpec struct {
	Attempts     int      `json:"attempts"`
	Delay        Duration `json:"delay"`
	MaximumDelay Duration `json:"maximumDelay"`
}

SyntheticCheckRetriesLinearSpec defines model for SyntheticCheckRetriesLinearSpec.

type SyntheticCheckRetriesOff

type SyntheticCheckRetriesOff struct {
	Kind SyntheticCheckRetriesOffKind `json:"kind"`
	Spec SyntheticCheckRetriesOffSpec `json:"spec"`
}

SyntheticCheckRetriesOff defines model for SyntheticCheckRetriesOff.

type SyntheticCheckRetriesOffKind

type SyntheticCheckRetriesOffKind string

SyntheticCheckRetriesOffKind defines model for SyntheticCheckRetriesOff.Kind.

const (
	Off SyntheticCheckRetriesOffKind = "off"
)

Defines values for SyntheticCheckRetriesOffKind.

type SyntheticCheckRetriesOffSpec

type SyntheticCheckRetriesOffSpec = interface{}

SyntheticCheckRetriesOffSpec defines model for SyntheticCheckRetriesOffSpec.

type SyntheticCheckSchedule

type SyntheticCheckSchedule struct {
	Interval  Duration                 `json:"interval"`
	Locations []SyntheticCheckLocation `json:"locations"`

	// Strategy Whether to run checks against all specified locations for every run, or just a single location per run.
	Strategy SyntheticCheckSchedulingStrategy `json:"strategy"`
}

SyntheticCheckSchedule defines model for SyntheticCheckSchedule.

type SyntheticCheckSchedulingStrategy

type SyntheticCheckSchedulingStrategy string

SyntheticCheckSchedulingStrategy Whether to run checks against all specified locations for every run, or just a single location per run.

const (
	AllLocations   SyntheticCheckSchedulingStrategy = "all_locations"
	RandomLocation SyntheticCheckSchedulingStrategy = "random_location"
)

Defines values for SyntheticCheckSchedulingStrategy.

type SyntheticCheckSpec

type SyntheticCheckSpec struct {
	Display       *SyntheticCheckDisplay      `json:"display,omitempty"`
	Enabled       bool                        `json:"enabled"`
	Labels        *map[string]string          `json:"labels,omitempty"`
	Notifications SyntheticCheckNotifications `json:"notifications"`
	Permissions   *[]SyntheticCheckPermission `json:"permissions,omitempty"`
	Plugin        SyntheticCheckPlugin        `json:"plugin"`
	Retries       SyntheticCheckRetries       `json:"retries"`
	Schedule      SyntheticCheckSchedule      `json:"schedule"`
}

SyntheticCheckSpec defines model for SyntheticCheckSpec.

type SyntheticChecksApiListItem

type SyntheticChecksApiListItem struct {
	Dataset string  `json:"dataset"`
	Id      string  `json:"id"`
	Name    *string `json:"name,omitempty"`
	Origin  *string `json:"origin,omitempty"`
}

SyntheticChecksApiListItem defines model for SyntheticChecksApiListItem.

type SyntheticHttpCheckAssertions

type SyntheticHttpCheckAssertions struct {
	CriticalAssertions HttpCheckAssertions `json:"criticalAssertions"`
	DegradedAssertions HttpCheckAssertions `json:"degradedAssertions"`
}

SyntheticHttpCheckAssertions defines model for SyntheticHttpCheckAssertions.

type SyntheticHttpCheckPlugin

type SyntheticHttpCheckPlugin struct {
	Kind SyntheticHttpCheckPluginKind `json:"kind"`
	Spec SyntheticHttpCheckPluginSpec `json:"spec"`
}

SyntheticHttpCheckPlugin defines model for SyntheticHttpCheckPlugin.

type SyntheticHttpCheckPluginKind

type SyntheticHttpCheckPluginKind string

SyntheticHttpCheckPluginKind defines model for SyntheticHttpCheckPlugin.Kind.

const (
	Http SyntheticHttpCheckPluginKind = "http"
)

Defines values for SyntheticHttpCheckPluginKind.

type SyntheticHttpCheckPluginSpec

type SyntheticHttpCheckPluginSpec struct {
	Assertions SyntheticHttpCheckAssertions `json:"assertions"`
	Request    HttpRequestSpec              `json:"request"`
}

SyntheticHttpCheckPluginSpec defines model for SyntheticHttpCheckPluginSpec.

type SyntheticHttpErrorType

type SyntheticHttpErrorType string

SyntheticHttpErrorType defines model for SyntheticHttpErrorType.

const (
	SyntheticHttpErrorTypeDns     SyntheticHttpErrorType = "dns"
	SyntheticHttpErrorTypeTcp     SyntheticHttpErrorType = "tcp"
	SyntheticHttpErrorTypeTimeout SyntheticHttpErrorType = "timeout"
	SyntheticHttpErrorTypeTls     SyntheticHttpErrorType = "tls"
	SyntheticHttpErrorTypeUnknown SyntheticHttpErrorType = "unknown"
)

Defines values for SyntheticHttpErrorType.

type TeamDefinition added in v1.4.0

type TeamDefinition struct {
	Kind     TeamDefinitionKind `json:"kind"`
	Metadata TeamMetadata       `json:"metadata"`
	Spec     TeamSpec           `json:"spec"`
}

TeamDefinition defines model for TeamDefinition.

type TeamDefinitionKind added in v1.4.0

type TeamDefinitionKind string

TeamDefinitionKind defines model for TeamDefinition.Kind.

const (
	Dash0Team TeamDefinitionKind = "Dash0Team"
)

Defines values for TeamDefinitionKind.

type TeamDisplay added in v1.4.0

type TeamDisplay struct {
	// Color A color gradient from one color to another.
	Color Gradient `json:"color"`
	Name  string   `json:"name"`
}

TeamDisplay defines model for TeamDisplay.

type TeamLabels added in v1.4.0

type TeamLabels struct {
	Dash0Comid     *string `json:"dash0.com/id,omitempty"`
	Dash0Comorigin *string `json:"dash0.com/origin,omitempty"`
}

TeamLabels defines model for TeamLabels.

type TeamMetadata added in v1.4.0

type TeamMetadata struct {
	Labels *TeamLabels `json:"labels,omitempty"`
	Name   string      `json:"name"`
}

TeamMetadata defines model for TeamMetadata.

type TeamSpec added in v1.4.0

type TeamSpec struct {
	Display TeamDisplay `json:"display"`
	Members []string    `json:"members"`
}

TeamSpec defines model for TeamSpec.

type TeamsListItem added in v1.4.0

type TeamsListItem struct {
	// Color A color gradient from one color to another.
	Color Gradient `json:"color"`
	Id    string   `json:"id"`

	// Members A sample of five members. You can inspect the total member count via `totalMemberCount`. This array
	// is restricted to at most five members, because this could otherwise be too much data.
	Members          []MemberDefinition `json:"members"`
	Name             string             `json:"name"`
	Origin           *string            `json:"origin,omitempty"`
	TotalMemberCount int                `json:"totalMemberCount"`
}

TeamsListItem defines model for TeamsListItem.

type TestSyntheticCheckRequest added in v1.4.0

type TestSyntheticCheckRequest struct {
	// Dataset Optional dataset to query across. Defaults to whatever is configured to be the default dataset for the organization.
	Dataset    *Dataset                 `json:"dataset,omitempty"`
	Definition SyntheticCheckDefinition `json:"definition"`
}

TestSyntheticCheckRequest defines model for TestSyntheticCheckRequest.

type TestSyntheticCheckResponse added in v1.4.0

type TestSyntheticCheckResponse struct {
	SyntheticCheckAttempt SyntheticCheckAttemptDetails `json:"syntheticCheckAttempt"`
}

TestSyntheticCheckResponse defines model for TestSyntheticCheckResponse.

type TimeRange

type TimeRange struct {
	// From A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	From FixedTime `json:"from"`

	// To A fixed point in time represented as an RFC 3339 date-time string.
	//
	// **Format**: `YYYY-MM-DDTHH:MM:SSZ` (UTC) or `YYYY-MM-DDTHH:MM:SS±HH:MM` (with timezone offset)
	//
	// **Examples**:
	// - `2024-01-15T14:30:00Z`
	// - `2024-01-15T14:30:00+08:00`
	To FixedTime `json:"to"`
}

TimeRange defines model for TimeRange.

type TimeReference

type TimeReference = any

TimeReference defines model for TimeReference.

type TimeReferenceRange

type TimeReferenceRange struct {
	From TimeReference `json:"from"`
	To   TimeReference `json:"to"`
}

TimeReferenceRange A range of time between two time references.

type TimingAssertion

type TimingAssertion struct {
	Kind TimingAssertionKind `json:"kind"`
	Spec TimingAssertionSpec `json:"spec"`
}

TimingAssertion defines model for TimingAssertion.

type TimingAssertionKind

type TimingAssertionKind string

TimingAssertionKind defines model for TimingAssertion.Kind.

const (
	Timing TimingAssertionKind = "timing"
)

Defines values for TimingAssertionKind.

type TimingAssertionSpec

type TimingAssertionSpec struct {
	Operator NumericAssertionOperator `json:"operator"`
	Type     TimingType               `json:"type"`
	Value    Duration                 `json:"value"`
}

TimingAssertionSpec defines model for TimingAssertionSpec.

type TimingType

type TimingType string

TimingType defines model for TimingType.

const (
	TimingTypeConnection TimingType = "connection"
	TimingTypeDns        TimingType = "dns"
	TimingTypeRequest    TimingType = "request"
	TimingTypeResponse   TimingType = "response"
	TimingTypeSsl        TimingType = "ssl"
	TimingTypeTotal      TimingType = "total"
)

Defines values for TimingType.

type TlsSettings

type TlsSettings struct {
	AllowInsecure bool `json:"allowInsecure"`
}

TlsSettings defines model for TlsSettings.

type TracingSettings

type TracingSettings struct {
	AddTracingHeaders bool `json:"addTracingHeaders"`
}

TracingSettings defines model for TracingSettings.

type Transport added in v1.8.0

type Transport struct {
	// contains filtered or unexported fields
}

Transport is a reusable HTTP transport stack that provides rate limiting and retry with exponential backoff. Build one with NewTransport and share it between raw http.Client usage and a typed Client via WithTransport.

A Transport is safe for concurrent use.

func NewTransport added in v1.8.0

func NewTransport(opts ...TransportOption) *Transport

NewTransport creates a configured Transport with rate limiting and retry. Values outside valid ranges are clamped silently.

Example:

t := dash0.NewTransport(
    dash0.WithTransportMaxRetries(3),
    dash0.WithTransportTimeout(10 * time.Second),
)
httpClient := t.HTTPClient()
Example
package main

import (
	"fmt"
	"time"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	t := dash0.NewTransport(
		dash0.WithTransportMaxRetries(3),
		dash0.WithTransportTimeout(10*time.Second),
	)
	fmt.Println(t.HTTPClient() != nil)
}
Output:
true

func (*Transport) HTTPClient added in v1.8.0

func (t *Transport) HTTPClient() *http.Client

HTTPClient returns a new http.Client that uses this transport's rate limiting and retry stack. Each call returns a new http.Client, but all returned clients share the same underlying transport so rate-limit budgets and concurrency limits are shared.

Example
package main

import (
	"fmt"

	dash0 "github.com/dash0hq/dash0-api-client-go"
)

func main() {
	t := dash0.NewTransport()
	httpClient := t.HTTPClient()
	fmt.Println(httpClient != nil)
}
Output:
true

func (*Transport) RoundTripper added in v1.8.0

func (t *Transport) RoundTripper() http.RoundTripper

RoundTripper returns the underlying http.RoundTripper with the full transport stack (rate limiting and retry) applied. Use this to plug the transport into an existing http.Client or other HTTP infrastructure.

type TransportOption added in v1.8.0

type TransportOption func(*transportConfig)

TransportOption configures a Transport.

func WithBaseTransport added in v1.8.0

func WithBaseTransport(rt http.RoundTripper) TransportOption

WithBaseTransport sets the underlying http.RoundTripper that the transport stack wraps. If not set, http.DefaultTransport is used.

func WithTransportMaxConcurrentRequests added in v1.8.0

func WithTransportMaxConcurrentRequests(n int64) TransportOption

WithTransportMaxConcurrentRequests sets the maximum number of concurrent API calls. The value must be between 1 and 10 (inclusive). Values outside this range will be clamped. Default is 3.

func WithTransportMaxRetries added in v1.8.0

func WithTransportMaxRetries(n int) TransportOption

WithTransportMaxRetries sets the maximum number of retries for failed requests. Only idempotent requests (GET, PUT, DELETE) and requests marked with withIdempotent context are retried. Default is 1. Maximum is 5. Set to 0 to disable retries.

func WithTransportRetryWaitMax added in v1.8.0

func WithTransportRetryWaitMax(d time.Duration) TransportOption

WithTransportRetryWaitMax sets the maximum wait time between retries. Default is 30s. The backoff will not exceed this value.

func WithTransportRetryWaitMin added in v1.8.0

func WithTransportRetryWaitMin(d time.Duration) TransportOption

WithTransportRetryWaitMin sets the minimum wait time between retries. Default is 500ms. The actual wait time uses exponential backoff starting from this value.

func WithTransportTimeout added in v1.8.0

func WithTransportTimeout(d time.Duration) TransportOption

WithTransportTimeout sets the HTTP request timeout applied to clients returned by Transport.HTTPClient. Default is 30 seconds.

type ViewAction

type ViewAction string

ViewAction defines model for ViewAction.

const (
	ViewsDelete ViewAction = "views:delete"
	ViewsRead   ViewAction = "views:read"
	ViewsWrite  ViewAction = "views:write"
)

Defines values for ViewAction.

type ViewAnnotations

type ViewAnnotations struct {
	Dash0ComdeletedAt  *time.Time `json:"dash0.com/deleted-at,omitempty"`
	Dash0ComfolderPath *string    `json:"dash0.com/folder-path,omitempty"`
	Dash0Comsharing    *string    `json:"dash0.com/sharing,omitempty"`
}

ViewAnnotations defines model for ViewAnnotations.

type ViewApiListItem

type ViewApiListItem struct {
	Dataset string  `json:"dataset"`
	Id      string  `json:"id"`
	Name    *string `json:"name,omitempty"`
	Origin  *string `json:"origin,omitempty"`

	// Type The view type describes where this view configuration is intended to be applied in the UI.
	Type ViewType `json:"type"`
}

ViewApiListItem defines model for ViewApiListItem.

type ViewDefinition

type ViewDefinition struct {
	Kind     ViewDefinitionKind `json:"kind"`
	Metadata ViewMetadata       `json:"metadata"`
	Spec     ViewSpec           `json:"spec"`
}

ViewDefinition defines model for ViewDefinition.

type ViewDefinitionKind

type ViewDefinitionKind string

ViewDefinitionKind defines model for ViewDefinition.Kind.

const (
	Dash0View ViewDefinitionKind = "Dash0View"
)

Defines values for ViewDefinitionKind.

type ViewDisplay

type ViewDisplay struct {
	// Description Long-form explanation what the view is doing. Shown within the list of views to help
	// team members understand the purpose of the view.
	Description *string `json:"description,omitempty"`

	// Name Short-form name for the view to be shown prominently within the view list and atop
	// the screen when the view is selected.
	Name string `json:"name"`
}

ViewDisplay defines model for ViewDisplay.

type ViewLabels

type ViewLabels struct {
	Dash0Comdataset *string                   `json:"dash0.com/dataset,omitempty"`
	Dash0Comid      *string                   `json:"dash0.com/id,omitempty"`
	Dash0Comorigin  *string                   `json:"dash0.com/origin,omitempty"`
	Dash0Comsource  *ViewLabelsDash0Comsource `json:"dash0.com/source,omitempty"`
	Dash0Comversion *string                   `json:"dash0.com/version,omitempty"`
}

ViewLabels defines model for ViewLabels.

type ViewLabelsDash0Comsource

type ViewLabelsDash0Comsource string

ViewLabelsDash0Comsource defines model for ViewLabels.Dash0Comsource.

const (
	Builtin     ViewLabelsDash0Comsource = "builtin"
	External    ViewLabelsDash0Comsource = "external"
	Userdefined ViewLabelsDash0Comsource = "userdefined"
)

Defines values for ViewLabelsDash0Comsource.

type ViewMetadata

type ViewMetadata struct {
	Annotations *ViewAnnotations `json:"annotations,omitempty"`
	Labels      *ViewLabels      `json:"labels,omitempty"`
	Name        string           `json:"name"`
}

ViewMetadata defines model for ViewMetadata.

type ViewPermission

type ViewPermission struct {
	// Actions Outlines possible actions that matching views can take with this view.
	Actions []ViewAction `json:"actions"`

	// Role Use role identifiers such as `admin` and `basic_member` to reference user groups.
	Role   *string `json:"role,omitempty"`
	TeamId *string `json:"teamId,omitempty"`
	UserId *string `json:"userId,omitempty"`
}

ViewPermission defines model for ViewPermission.

type ViewSpec

type ViewSpec struct {
	Display ViewDisplay     `json:"display"`
	Filter  *FilterCriteria `json:"filter,omitempty"`

	// GroupBy A set of attribute keys to group the view by. This property may be missing to indicate that
	// no configuration was historically made for this view, i.e., the view was saved before the
	// grouping capability was added. In that case, you can assume a default grouping should be used.
	GroupBy        *[]string         `json:"groupBy,omitempty"`
	ImplicitFilter *FilterCriteria   `json:"implicitFilter,omitempty"`
	Permissions    *[]ViewPermission `json:"permissions,omitempty"`

	// Query The SQL query associated with this view. Only applicable when type is "sql".
	// When the view is loaded, this query is used to populate the editor and auto-executed.
	Query                *string                       `json:"query,omitempty"`
	ServiceMapProperties *ViewSpecServiceMapProperties `json:"serviceMapProperties,omitempty"`
	Table                *ViewTable                    `json:"table,omitempty"`

	// Type The view type describes where this view configuration is intended to be applied in the UI.
	Type ViewType `json:"type"`

	// Visualizations A visualization configuration for the view. We only support a single visualization for now per view.
	Visualizations *[]ViewVisualization `json:"visualizations,omitempty"`
}

ViewSpec defines model for ViewSpec.

type ViewSpecServiceMapProperties added in v1.2.0

type ViewSpecServiceMapProperties struct {
	// ExpandedGroups A list of expanded group identifiers in the service map. When external services are grouped,
	// individual groups can be expanded to show all services within. This list stores which groups
	// are currently expanded.
	ExpandedGroups   *[]string                                    `json:"expandedGroups,omitempty"`
	ExternalServices ViewSpecServiceMapPropertiesExternalServices `json:"externalServices"`
	Layout           ViewSpecServiceMapPropertiesLayout           `json:"layout"`
	NodeSizing       bool                                         `json:"nodeSizing"`
	Particles        bool                                         `json:"particles"`
	SelectedMetric   string                                       `json:"selectedMetric"`
}

ViewSpecServiceMapProperties defines model for ViewSpecServiceMapProperties.

type ViewSpecServiceMapPropertiesExternalServices added in v1.2.0

type ViewSpecServiceMapPropertiesExternalServices string

ViewSpecServiceMapPropertiesExternalServices defines model for ViewSpecServiceMapProperties.ExternalServices.

Defines values for ViewSpecServiceMapPropertiesExternalServices.

type ViewSpecServiceMapPropertiesLayout added in v1.2.0

type ViewSpecServiceMapPropertiesLayout string

ViewSpecServiceMapPropertiesLayout defines model for ViewSpecServiceMapProperties.Layout.

Defines values for ViewSpecServiceMapPropertiesLayout.

type ViewTable

type ViewTable struct {
	Columns []ViewTableColumn `json:"columns"`

	// Sort Any supported attribute keys to order by.
	Sort OrderingCriteria `json:"sort"`
}

ViewTable defines model for ViewTable.

type ViewTableColumn

type ViewTableColumn struct {
	// ColSize A CSS grid layout sizing instruction. Supports hard-coded sizing such as `7rem`, but also `min-content`
	// and similar variants.
	ColSize *string `json:"colSize,omitempty"`

	// Key The key of the attribute to be displayed in this column. This can also be a built-in column name.
	Key   string  `json:"key"`
	Label *string `json:"label,omitempty"`
}

ViewTableColumn defines model for ViewTableColumn.

type ViewType

type ViewType string

ViewType The view type describes where this view configuration is intended to be applied in the UI.

const (
	FailedChecks ViewType = "failed_checks"
	Logs         ViewType = "logs"
	Metrics      ViewType = "metrics"
	Resources    ViewType = "resources"
	Services     ViewType = "services"
	Spans        ViewType = "spans"
	Sql          ViewType = "sql"
	WebEvents    ViewType = "web_events"
)

Defines values for ViewType.

type ViewVisualization

type ViewVisualization struct {
	Metric *ViewVisualizationMetric `json:"metric,omitempty"`

	// Renderer The renderer type for the visualization. The pattern matching is inspired by glob, where `*` can be used as a wildcard.
	// The matching prioritizes precise matches before wildcard matches.
	// If there are multiple renderers, select buttons will be added to allow toggling between the renderers.
	Renderer *ViewVisualizationRenderer `json:"renderer,omitempty"`

	// Renderers A set of visualizations (charts) to render as part of this view. We currently only expect
	// to render a single
	Renderers  []ViewVisualizationRenderer `json:"renderers"`
	YAxisScale *AxisScale                  `json:"yAxisScale,omitempty"`
}

ViewVisualization defines model for ViewVisualization.

type ViewVisualizationMetric

type ViewVisualizationMetric string

ViewVisualizationMetric defines model for ViewVisualizationMetric.

const (
	LogsRate              ViewVisualizationMetric = "logs_rate"
	LogsTotal             ViewVisualizationMetric = "logs_total"
	SpansDurationAvg      ViewVisualizationMetric = "spans_duration_avg"
	SpansDurationP50      ViewVisualizationMetric = "spans_duration_p50"
	SpansDurationP75      ViewVisualizationMetric = "spans_duration_p75"
	SpansDurationP90      ViewVisualizationMetric = "spans_duration_p90"
	SpansDurationP95      ViewVisualizationMetric = "spans_duration_p95"
	SpansDurationP99      ViewVisualizationMetric = "spans_duration_p99"
	SpansErrorsPercentage ViewVisualizationMetric = "spans_errors_percentage"
	SpansErrorsRate       ViewVisualizationMetric = "spans_errors_rate"
	SpansErrorsTotal      ViewVisualizationMetric = "spans_errors_total"
	SpansRate             ViewVisualizationMetric = "spans_rate"
	SpansTotal            ViewVisualizationMetric = "spans_total"
)

Defines values for ViewVisualizationMetric.

type ViewVisualizationRenderer

type ViewVisualizationRenderer string

ViewVisualizationRenderer The renderer type for the visualization. The pattern matching is inspired by glob, where `*` can be used as a wildcard. The matching prioritizes precise matches before wildcard matches. If there are multiple renderers, select buttons will be added to allow toggling between the renderers.

const (
	LoggingstackedBar                    ViewVisualizationRenderer = "logging/*/stacked_bar"
	Resourcesfaasred                     ViewVisualizationRenderer = "resources/faas/red"
	Resourcesk8sCronJobsexecutions       ViewVisualizationRenderer = "resources/k8s-cron-jobs/executions"
	Resourcesk8sCronJobsred              ViewVisualizationRenderer = "resources/k8s-cron-jobs/red"
	Resourcesk8sDaemonSetsred            ViewVisualizationRenderer = "resources/k8s-daemon-sets/red"
	Resourcesk8sDaemonSetsscheduledNodes ViewVisualizationRenderer = "resources/k8s-daemon-sets/scheduled-nodes"
	Resourcesk8sDeploymentsred           ViewVisualizationRenderer = "resources/k8s-deployments/red"
	Resourcesk8sDeploymentsreplicas      ViewVisualizationRenderer = "resources/k8s-deployments/replicas"
	Resourcesk8sJobsexecutions           ViewVisualizationRenderer = "resources/k8s-jobs/executions"
	Resourcesk8sJobsred                  ViewVisualizationRenderer = "resources/k8s-jobs/red"
	Resourcesk8sNamespacesred            ViewVisualizationRenderer = "resources/k8s-namespaces/red"
	Resourcesk8sNodescpuMemoryDisk       ViewVisualizationRenderer = "resources/k8s-nodes/cpu-memory-disk"
	Resourcesk8sNodesstatus              ViewVisualizationRenderer = "resources/k8s-nodes/status"
	Resourcesk8sPodscpuMemory            ViewVisualizationRenderer = "resources/k8s-pods/cpu-memory"
	Resourcesk8sPodsred                  ViewVisualizationRenderer = "resources/k8s-pods/red"
	Resourcesk8sPodsstatus               ViewVisualizationRenderer = "resources/k8s-pods/status"
	Resourcesk8sReplicaSetsred           ViewVisualizationRenderer = "resources/k8s-replica-sets/red"
	Resourcesk8sReplicaSetsreplicas      ViewVisualizationRenderer = "resources/k8s-replica-sets/replicas"
	Resourcesk8sStatefulSetsred          ViewVisualizationRenderer = "resources/k8s-stateful-sets/red"
	Resourcesk8sStatefulSetsreplicas     ViewVisualizationRenderer = "resources/k8s-stateful-sets/replicas"
	Resourcesnamesred                    ViewVisualizationRenderer = "resources/names/red"
	Resourcesoperationsred               ViewVisualizationRenderer = "resources/operations/red"
	Resourcesoverviewoverview            ViewVisualizationRenderer = "resources/overview/overview"
	Resourcesservicesred                 ViewVisualizationRenderer = "resources/services/red"
	ResourcestableTree                   ViewVisualizationRenderer = "resources/*/table-tree"
	TracesExploreroutliers               ViewVisualizationRenderer = "traces-explorer/*/outliers"
	TracesExplorerred                    ViewVisualizationRenderer = "traces-explorer/*/red"
)

Defines values for ViewVisualizationRenderer.

Directories

Path Synopsis
Package dash0test provides testing utilities for the Dash0 API client.
Package dash0test provides testing utilities for the Dash0 API client.
Package profiles manages named Dash0 configuration profiles.
Package profiles manages named Dash0 configuration profiles.
tools
postprocess command
Command postprocess applies transformations to generated.go to fix conflicts introduced by oapi-codegen that cannot be resolved via configuration alone.
Command postprocess applies transformations to generated.go to fix conflicts introduced by oapi-codegen that cannot be resolved via configuration alone.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL