action_kit_api

package module
v2.9.6 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2024 License: MIT Imports: 12 Imported by: 63

README

ActionKit Go API

This module exposes Go types that you will find helpful when implementing an ActionKit extension.

The types are generated automatically from the ActionKit OpenAPI specification.

Installation

Add the following to your go.mod file:

go get github.com/steadybit/action-kit/go/action_kit_api

Usage

import (
	"github.com/steadybit/action-kit/go/action_kit_api"
)

actionList := action_kit_api.ActionList{
    Actions: []action_kit_api.DescribingEndpointReference{
        {
            "GET",
            "/actions/rollout-restart",
        },
    },
}

Documentation

Overview

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

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

Index

Constants

View Source
const (
	// Deprecated: Use action_kit_api.ActionParameterTypeBitrate instead.
	Bitrate ActionParameterType = "bitrate"
	// Deprecated: Use action_kit_api.ActionParameterTypeBoolean instead.
	Boolean ActionParameterType = "boolean"
	// Deprecated: Use action_kit_api.ActionParameterTypeDuration instead.
	Duration ActionParameterType = "duration"
	// Deprecated: Use action_kit_api.ActionParameterTypeFile instead.
	File ActionParameterType = "file"
	// Deprecated: Use action_kit_api.ActionParameterTypeHeader instead.
	Header ActionParameterType = "header"
	// Deprecated: Use action_kit_api.ActionParameterTypeInteger instead.
	Integer ActionParameterType = "integer"
	// Deprecated: Use action_kit_api.ActionParameterTypeKeyValue instead.
	KeyValue ActionParameterType = "key_value"
	// Deprecated: Use action_kit_api.ActionParameterTypePercentage instead.
	Percentage ActionParameterType = "percentage"
	// Deprecated: Use action_kit_api.ActionParameterTypeRegex instead.
	Regex ActionParameterType = "regex"
	// Deprecated: Use action_kit_api.ActionParameterTypeSeparator instead.
	Separator ActionParameterType = "separator"
	// Deprecated: Use action_kit_api.ActionParameterTypeStressngWorkers instead.
	StressngWorkers ActionParameterType = "stressng-workers"
	// Deprecated: Use action_kit_api.ActionParameterTypeString instead.
	String ActionParameterType = "string"
	// Deprecated: Use action_kit_api.ActionParameterTypeString1 instead.
	String1 ActionParameterType = "string[]"
	// Deprecated: Use action_kit_api.ActionParameterTypeStringArray instead.
	StringArray ActionParameterType = "string_array"
	// Deprecated: Use action_kit_api.ActionParameterTypeStringTextarea instead.
	Textarea ActionParameterType = "textarea"
	// Deprecated: Use action_kit_api.ActionParameterTypeStringUrl instead.
	Url ActionParameterType = "url"

	// Deprecated: Use action_kit_api.QuantityRestrictionAll instead.
	All TargetSelectionQuantityRestriction = "all"
	// Deprecated: Use action_kit_api.QuantityRestrictionExactlyOne instead.
	ExactlyOne TargetSelectionQuantityRestriction = "exactly_one"
	// Deprecated: Use action_kit_api.QuantityRestrictionNone instead.
	None TargetSelectionQuantityRestriction = "none"
)

Variables

This section is empty.

Functions

func GetSwagger added in v2.7.2

func GetSwagger() (swagger *openapi3.T, err error)

GetSwagger returns the Swagger specification corresponding to the generated code in this file. The external references of Swagger specification are resolved. The logic of resolving external references is tightly connected to "import-mapping" feature. Externally referenced files must be embedded in the corresponding golang packages. Urls can be supported but this task was out of the scope.

func PathToRawSpec added in v2.7.2

func PathToRawSpec(pathToFile string) map[string]func() ([]byte, error)

Constructs a synthetic filesystem for resolving external references when loading openapi specifications.

Types

type ActionDescription

type ActionDescription struct {
	// AdditionalFlags Additional flags that are used to configure the action for specific cases:
	//   * `DISABLE_HEARTBEAT` - Disable the heartbeat between agent and platform for this action during execution
	AdditionalFlags *[]ActionDescriptionAdditionalFlags `json:"additionalFlags,omitempty"`

	// Category Used for categorization of the action within user interfaces. This is optional and mostly used as sub-category if certain actions should be grouped together.
	Category *string `json:"category,omitempty"`

	// Description Description for end-users to help them understand what the action is doing.
	Description string `json:"description"`

	// Hint Hints are used to provide additional information to the user. They are rendered in the ui when the user is configuring the action.
	Hint *ActionHint `json:"hint,omitempty"`

	// Icon An icon that is used to identify your action in the ui. Needs to be a data-uri containing an image.
	Icon *string `json:"icon,omitempty"`

	// Id A technical ID that is used to uniquely identify this type of action. You will typically want to use something like `org.example.my-fancy-attack`.
	Id string `json:"id"`

	// Kind Describes what kind of action this is. This is used to help users understand and classify the various runnable actions that are part of an experiment.
	Kind ActionKind `json:"kind"`

	// Label A human-readable label for the action.
	Label   string                `json:"label"`
	Metrics *MetricsConfiguration `json:"metrics,omitempty"`

	// Parameters Parameters that are used to configure the action. These parameters will be rendered in the ui and will be validated.
	Parameters []ActionParameter `json:"parameters"`

	// Prepare HTTP endpoint which the Steadybit platform/agent could communicate with.
	Prepare MutatingEndpointReference `json:"prepare"`

	// Start HTTP endpoint which the Steadybit platform/agent could communicate with.
	Start MutatingEndpointReference `json:"start"`

	// Status HTTP endpoint which the Steadybit platform/agent could communicate with.
	Status *MutatingEndpointReferenceWithCallInterval `json:"status,omitempty"`

	// Stop HTTP endpoint which the Steadybit platform/agent could communicate with.
	Stop *MutatingEndpointReference `json:"stop,omitempty"`

	// TargetSelection Used to specify various aspects of the target selection. If the action don't need a target selection, this field can be omitted.
	TargetSelection *TargetSelection `json:"targetSelection,omitempty"`
	// Deprecated: Use `TargetSelection.selectionTemplates` instead.
	TargetSelectionTemplates *TargetSelectionTemplates `json:"targetSelectionTemplates,omitempty"`
	// Deprecated: Use `TargetSelection.targetType` instead.
	TargetType *string `json:"targetType,omitempty"`

	// Technology Used for categorization of the action within user interfaces. In most cases, this will be the technology that the extension is about to handle, for example `AWS`, `Kubernetes` or `Host` or any custom technology you are writing an extension for.
	Technology *string `json:"technology,omitempty"`

	// TimeControl Actions can either be an instantaneous event, e.g., the restart of a host, or an activity spanning over an unspecified duration. For those actions having a duration, we differentiate between internally, e.g., waiting for a deployment to finish, and externally, e.g., waiting for a user-specified time to pass, controlled durations.
	TimeControl TimeControl `json:"timeControl"`

	// Version The version of the action. Remember to increase the value everytime you update the definitions. The platform will ignore any definition changes with the same action version. We do recommend usage of semver strings.
	Version string `json:"version"`

	// Widgets Widgets that will be rendered in the experiment result view after an experiment has finished.
	Widgets *Widgets `json:"widgets,omitempty"`
}

ActionDescription Provides details about a possible action, e.g., what configuration options it has, how to present it to end-users and how to trigger the action.

type ActionDescriptionAdditionalFlags added in v2.5.2

type ActionDescriptionAdditionalFlags string

ActionDescriptionAdditionalFlags defines model for ActionDescription.AdditionalFlags.

const (
	DISABLEHEARTBEAT ActionDescriptionAdditionalFlags = "DISABLE_HEARTBEAT"
)

Defines values for ActionDescriptionAdditionalFlags.

type ActionHint added in v2.4.0

type ActionHint struct {
	// Content The actual hint text (can contain markdown). Will be displayed in the product UI when configuring the action.
	Content string `json:"content"`

	// Type Will be used in the product UI to display the hint in a different color and with a different icon.
	Type ActionHintType `json:"type"`
}

ActionHint Hints are used to provide additional information to the user. They are rendered in the ui when the user is configuring the action.

type ActionHintType added in v2.4.0

type ActionHintType string

ActionHintType Will be used in the product UI to display the hint in a different color and with a different icon.

const (
	HintInfo    ActionHintType = "hint_info"
	HintWarning ActionHintType = "hint_warning"
)

Defines values for ActionHintType.

type ActionKind added in v2.7.0

type ActionKind string

ActionKind Describes what kind of action this is. This is used to help users understand and classify the various runnable actions that are part of an experiment.

const (
	Attack   ActionKind = "attack"
	Check    ActionKind = "check"
	LoadTest ActionKind = "load_test"
	Other    ActionKind = "other"
)

Defines values for ActionKind.

type ActionKitError

type ActionKitError struct {
	// Detail A human-readable explanation specific to this occurrence of the problem.
	Detail *string `json:"detail,omitempty"`

	// Instance A URI reference that identifies the specific occurrence of the problem.
	Instance *string `json:"instance,omitempty"`

	// Status * failed - The action has detected some failures, for example a failing test which has been implemented by the action. The action will be stopped, if this status is returned by the status endpoint. * errored - There was a technical error while executing the action. Will be marked as red in the platform. The action will be stopped, if this status is returned by the status endpoint.
	Status *ActionKitErrorStatus `json:"status,omitempty"`

	// Title A short, human-readable summary of the problem type.
	Title string `json:"title"`

	// Type A URI reference that identifies the problem type.
	Type *string `json:"type,omitempty"`
}

ActionKitError An enhanced version of RFC 7807 Problem Details for HTTP APIs compliant response body for error scenarios

type ActionKitErrorStatus added in v2.0.1

type ActionKitErrorStatus string

ActionKitErrorStatus * failed - The action has detected some failures, for example a failing test which has been implemented by the action. The action will be stopped, if this status is returned by the status endpoint. * errored - There was a technical error while executing the action. Will be marked as red in the platform. The action will be stopped, if this status is returned by the status endpoint.

const (
	Errored ActionKitErrorStatus = "errored"
	Failed  ActionKitErrorStatus = "failed"
)

Defines values for ActionKitErrorStatus.

type ActionList

type ActionList struct {
	Actions []DescribingEndpointReference `json:"actions"`
}

ActionList Lists all actions that the platform/agent could execute.

type ActionListResponse

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

ActionListResponse defines model for ActionListResponse.

func (ActionListResponse) AsActionKitError

func (t ActionListResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the ActionListResponse as a ActionKitError

func (ActionListResponse) AsActionList

func (t ActionListResponse) AsActionList() (ActionList, error)

AsActionList returns the union data inside the ActionListResponse as a ActionList

func (*ActionListResponse) FromActionKitError

func (t *ActionListResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the ActionListResponse as the provided ActionKitError

func (*ActionListResponse) FromActionList

func (t *ActionListResponse) FromActionList(v ActionList) error

FromActionList overwrites any union data inside the ActionListResponse as the provided ActionList

func (ActionListResponse) MarshalJSON

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

func (*ActionListResponse) MergeActionKitError added in v2.6.4

func (t *ActionListResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the ActionListResponse, using the provided ActionKitError

func (*ActionListResponse) MergeActionList added in v2.6.4

func (t *ActionListResponse) MergeActionList(v ActionList) error

MergeActionList performs a merge with any union data inside the ActionListResponse, using the provided ActionList

func (*ActionListResponse) UnmarshalJSON

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

type ActionParameter

type ActionParameter struct {
	// AcceptedFileTypes Unique file type specifiers describing what type of files are accepted for parameters of type 'file'.
	AcceptedFileTypes *[]string `json:"acceptedFileTypes,omitempty"`

	// Advanced Whether this parameter should be placed under the expandable advanced section within the user interface.
	Advanced *bool `json:"advanced,omitempty"`

	// DefaultValue A default value for this parameter. This value will be used if the user does not specify a value for this parameter.
	DefaultValue *string `json:"defaultValue,omitempty"`

	// Deprecated Whether or not this parameter is deprecated. Deprecated parameters will be hidden from the user interface when configuring a new step. Existing steps will still be able to use deprecated parameters. A deprecated parameter should not be required nor have a defaultValue.
	Deprecated *bool `json:"deprecated,omitempty"`

	// DeprecationMessage A message that will be shown to the user when they are configuring the action. This could for example include a hint to use a replacement.
	DeprecationMessage *string `json:"deprecationMessage,omitempty"`

	// Description Description for end-users to help them understand the action parameter.
	Description *string `json:"description,omitempty"`

	// Hint Hints are used to provide additional information to the user. They are rendered in the ui when the user is configuring the action.
	Hint *ActionHint `json:"hint,omitempty"`

	// Label A human-readable label for the action parameter.
	Label string `json:"label"`

	// MaxValue The minimum value for this parameter. Only applicable for parameters of type `integer` and `percentage`.
	MaxValue *int `json:"maxValue,omitempty"`

	// MinValue The minimum value for this parameter. Only applicable for parameters of type `integer` and `percentage`.
	MinValue *int `json:"minValue,omitempty"`

	// Name The key under which the action parameter is stored. This key can then be found within the prepare request's config field.
	Name string `json:"name"`

	// Options Optional options for the `string`, `string[]` and `string_array` parameter types. Which result in suggestions for end-users. Any of:
	//  - `action_kit_api.ExplicitParameterOption`
	//  - `action_kit_api.ParameterOptionsFromTargetAttribute`
	Options *[]ParameterOption `json:"options,omitempty"`

	// OptionsOnly Define if for a type = 'string' with options, if only the options should be allowed or also free text. Default is true.
	OptionsOnly *bool `json:"optionsOnly,omitempty"`
	// Deprecated: The position in the list will determine the order.
	Order *int `json:"order,omitempty"`

	// Required Whether or not end-users need to specify a value for this parameter.
	Required *bool `json:"required,omitempty"`

	// Type What kind of value this parameter is capturing. The type selection influences the `config` passed as part of the `PrepareRequest`. It also results in improved user-interface elements.
	Type ActionParameterType `json:"type"`
}

ActionParameter defines model for ActionParameter.

type ActionParameterType

type ActionParameterType string

ActionParameterType What kind of value this parameter is capturing. The type selection influences the `config` passed as part of the `PrepareRequest`. It also results in improved user-interface elements.

const (
	ActionParameterTypeBitrate         ActionParameterType = "bitrate"
	ActionParameterTypeBoolean         ActionParameterType = "boolean"
	ActionParameterTypeDuration        ActionParameterType = "duration"
	ActionParameterTypeFile            ActionParameterType = "file"
	ActionParameterTypeHeader          ActionParameterType = "header"
	ActionParameterTypeInteger         ActionParameterType = "integer"
	ActionParameterTypeKeyValue        ActionParameterType = "key_value"
	ActionParameterTypePercentage      ActionParameterType = "percentage"
	ActionParameterTypeRegex           ActionParameterType = "regex"
	ActionParameterTypeSeparator       ActionParameterType = "separator"
	ActionParameterTypeStressngWorkers ActionParameterType = "stressng-workers"
	ActionParameterTypeString          ActionParameterType = "string"
	ActionParameterTypeString1         ActionParameterType = "string[]"
	ActionParameterTypeStringArray     ActionParameterType = "string_array"
	ActionParameterTypeTargetSelection ActionParameterType = "target-selection"
	ActionParameterTypeTextarea        ActionParameterType = "textarea"
	ActionParameterTypeUrl             ActionParameterType = "url"
)

Defines values for ActionParameterType.

type ActionState

type ActionState map[string]interface{}

ActionState Any kind of action specific state that will be passed to the next endpoints.

type ActionStatusRequestBody

type ActionStatusRequestBody struct {
	ExecutionId uuid.UUID `json:"executionId"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State ActionState `json:"state"`
}

ActionStatusRequestBody defines model for ActionStatusRequestBody.

type ActionStatusResponse

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

ActionStatusResponse defines model for ActionStatusResponse.

func (ActionStatusResponse) AsActionKitError

func (t ActionStatusResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the ActionStatusResponse as a ActionKitError

func (ActionStatusResponse) AsStatusResult

func (t ActionStatusResponse) AsStatusResult() (StatusResult, error)

AsStatusResult returns the union data inside the ActionStatusResponse as a StatusResult

func (*ActionStatusResponse) FromActionKitError

func (t *ActionStatusResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the ActionStatusResponse as the provided ActionKitError

func (*ActionStatusResponse) FromStatusResult

func (t *ActionStatusResponse) FromStatusResult(v StatusResult) error

FromStatusResult overwrites any union data inside the ActionStatusResponse as the provided StatusResult

func (ActionStatusResponse) MarshalJSON

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

func (*ActionStatusResponse) MergeActionKitError added in v2.6.4

func (t *ActionStatusResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the ActionStatusResponse, using the provided ActionKitError

func (*ActionStatusResponse) MergeStatusResult added in v2.6.4

func (t *ActionStatusResponse) MergeStatusResult(v StatusResult) error

MergeStatusResult performs a merge with any union data inside the ActionStatusResponse, using the provided StatusResult

func (*ActionStatusResponse) UnmarshalJSON

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

type Artifact

type Artifact struct {
	// Data base64 encoded data
	Data string `json:"data"`

	// Label Human-readable label for the artifact. We recommend to include file extensions within the label for a better user-experience when downloading these artifacts, e.g., load_test_result.tar.gz.
	Label string `json:"label"`
}

Artifact Actions may choose to provide artifacts (arbitrary files) that are later accessible by users when inspecting experiment execution details. This comes in handy to expose load test reports and similar data.

type Artifacts

type Artifacts = []Artifact

Artifacts defines model for Artifacts.

type DefaultBlastRadius added in v2.9.5

type DefaultBlastRadius struct {
	// Mode The mode of the randomizer. If set to `percentage`, the platform will pick n percent of the selected targets. If set to `maximum`, the randomizer pick n targets.
	Mode DefaultBlastRadiusMode `json:"mode"`

	// Value If the mode is set to `percentage`, the value is the percentage of the selected targets. If the mode is set to `maximum`, the value is the number of targets.
	Value int `json:"value"`
}

DefaultBlastRadius The default blast radius configuration for the action. (Default: 100 percent)

type DefaultBlastRadiusMode added in v2.9.5

type DefaultBlastRadiusMode string

DefaultBlastRadiusMode The mode of the randomizer. If set to `percentage`, the platform will pick n percent of the selected targets. If set to `maximum`, the randomizer pick n targets.

const (
	DefaultBlastRadiusModeMaximum    DefaultBlastRadiusMode = "maximum"
	DefaultBlastRadiusModePercentage DefaultBlastRadiusMode = "percentage"
)

Defines values for DefaultBlastRadiusMode.

type DescribeActionResponse

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

DescribeActionResponse defines model for DescribeActionResponse.

func (DescribeActionResponse) AsActionDescription

func (t DescribeActionResponse) AsActionDescription() (ActionDescription, error)

AsActionDescription returns the union data inside the DescribeActionResponse as a ActionDescription

func (DescribeActionResponse) AsActionKitError

func (t DescribeActionResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the DescribeActionResponse as a ActionKitError

func (*DescribeActionResponse) FromActionDescription

func (t *DescribeActionResponse) FromActionDescription(v ActionDescription) error

FromActionDescription overwrites any union data inside the DescribeActionResponse as the provided ActionDescription

func (*DescribeActionResponse) FromActionKitError

func (t *DescribeActionResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the DescribeActionResponse as the provided ActionKitError

func (DescribeActionResponse) MarshalJSON

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

func (*DescribeActionResponse) MergeActionDescription added in v2.6.4

func (t *DescribeActionResponse) MergeActionDescription(v ActionDescription) error

MergeActionDescription performs a merge with any union data inside the DescribeActionResponse, using the provided ActionDescription

func (*DescribeActionResponse) MergeActionKitError added in v2.6.4

func (t *DescribeActionResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the DescribeActionResponse, using the provided ActionKitError

func (*DescribeActionResponse) UnmarshalJSON

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

type DescribingEndpointReference

type DescribingEndpointReference struct {
	Method ReadHttpMethod `json:"method"`

	// Path Absolute path of the HTTP endpoint.
	Path string `json:"path"`
}

DescribingEndpointReference HTTP endpoint which the Steadybit platform/agent could communicate with.

type ExecutionContext added in v2.4.2

type ExecutionContext struct {
	// AgentAwsAccountId The AWS account ID of the agent that is executing the action. This is only set when the action is executed on an AWS account
	AgentAwsAccountId *string `json:"agentAwsAccountId,omitempty"`

	// AgentPid The process ID of the agent that is executing the action.
	AgentPid *int `json:"agentPid,omitempty"`

	// ExecutionId The execution ID of the current execution.
	ExecutionId *int `json:"executionId,omitempty"`

	// ExecutionUri The execution URI of the current execution.
	ExecutionUri *string `json:"executionUri,omitempty"`

	// ExperimentKey The experiment key of the experiment that is currently being executed.
	ExperimentKey *string `json:"experimentKey,omitempty"`

	// ExperimentUri The experiment URI of the experiment that is currently being executed.
	ExperimentUri *string `json:"experimentUri,omitempty"`

	// RestrictedEndpoints Endpoints that are used by the agent (e.g to communicate with extensions and platform). These Connections shall not be affected by actions / attacks.
	RestrictedEndpoints *[]RestrictedEndpoint `json:"restrictedEndpoints,omitempty"`
}

ExecutionContext The execution context contains information about the current execution of the action.

type ExplicitParameterOption

type ExplicitParameterOption struct {
	// Label A human-readable label describing this option.
	Label string `json:"label"`

	// Value The technical value which will be passed to the action as part of the `config` object.
	Value string `json:"value"`
}

ExplicitParameterOption You can use an explicit/fixed parameter option for a known / finite set of options that never change.

type LineChartWidget added in v2.9.4

type LineChartWidget struct {
	// Grouping Optional configuration to group some data points in the line chart. Groups can be colored and a summary can be shown in an Pie chart next to the line chart.
	Grouping *LineChartWidgetGroupingConfig `json:"grouping,omitempty"`
	Identity LineChartWidgetIdentityConfig  `json:"identity"`

	// Title The title of the widget. This will be displayed in the widget header.
	Title   string                        `json:"title"`
	Tooltip *LineChartWidgetTooltipConfig `json:"tooltip,omitempty"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChart`.
	Type LineChartWidgetType `json:"type"`
}

LineChartWidget A widget that shows a line chart.

type LineChartWidgetGroup added in v2.9.4

type LineChartWidgetGroup struct {
	// Color The color of the group. This will be used to color the matching data points in the line chart.
	Color string `json:"color"`

	// Matcher The matcher that should be used to match the data points that should be part of this group. Any of
	//  - `action_kit_api.LineChartWidgetGroupMatcherFallback`
	//  - `action_kit_api.LineChartWidgetGroupMatcherKeyEqualsValue`
	//  - `action_kit_api.LineChartWidgetGroupMatcherNotEmpty`
	Matcher LineChartWidgetGroupMatcher `json:"matcher"`

	// Title The title of the group. This will be displayed in the tooltip and the pie chart summary of the widget
	Title string `json:"title"`
}

LineChartWidgetGroup A group of data points in the line chart.

type LineChartWidgetGroupMatcher added in v2.9.4

type LineChartWidgetGroupMatcher interface{}

type LineChartWidgetGroupMatcherFallback added in v2.9.4

type LineChartWidgetGroupMatcherFallback struct {
	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherFallback`.
	Type LineChartWidgetGroupMatcherFallbackType `json:"type"`
}

LineChartWidgetGroupMatcherFallback A fallback matcher that will match all data points that are not matched by any other group.

type LineChartWidgetGroupMatcherFallbackType added in v2.9.4

type LineChartWidgetGroupMatcherFallbackType string

LineChartWidgetGroupMatcherFallbackType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherFallback`.

const (
	ComSteadybitWidgetLineChartGroupMatcherFallback LineChartWidgetGroupMatcherFallbackType = "com.steadybit.widget.line_chart.group_matcher_fallback"
)

Defines values for LineChartWidgetGroupMatcherFallbackType.

type LineChartWidgetGroupMatcherKeyEqualsValue added in v2.9.4

type LineChartWidgetGroupMatcherKeyEqualsValue struct {
	Key string `json:"key"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherKeyEqualsValue`.
	Type  LineChartWidgetGroupMatcherKeyEqualsValueType `json:"type"`
	Value string                                        `json:"value"`
}

LineChartWidgetGroupMatcherKeyEqualsValue A matcher that will match all data points where the value of the specified key equals the specified value.

type LineChartWidgetGroupMatcherKeyEqualsValueType added in v2.9.4

type LineChartWidgetGroupMatcherKeyEqualsValueType string

LineChartWidgetGroupMatcherKeyEqualsValueType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherKeyEqualsValue`.

const (
	ComSteadybitWidgetLineChartGroupMatcherKeyEqualsValue LineChartWidgetGroupMatcherKeyEqualsValueType = "com.steadybit.widget.line_chart.group_matcher_key_equals_value"
)

Defines values for LineChartWidgetGroupMatcherKeyEqualsValueType.

type LineChartWidgetGroupMatcherNotEmpty added in v2.9.4

type LineChartWidgetGroupMatcherNotEmpty struct {
	Key string `json:"key"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherNotEmpty`.
	Type LineChartWidgetGroupMatcherNotEmptyType `json:"type"`
}

LineChartWidgetGroupMatcherNotEmpty A matcher that will match all data points where the value of the specified key is not empty.

type LineChartWidgetGroupMatcherNotEmptyType added in v2.9.4

type LineChartWidgetGroupMatcherNotEmptyType string

LineChartWidgetGroupMatcherNotEmptyType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChartGroupMatcherNotEmpty`.

const (
	ComSteadybitWidgetLineChartGroupMatcherNotEmpty LineChartWidgetGroupMatcherNotEmptyType = "com.steadybit.widget.line_chart.group_matcher_not_empty"
)

Defines values for LineChartWidgetGroupMatcherNotEmptyType.

type LineChartWidgetGroupingConfig added in v2.9.4

type LineChartWidgetGroupingConfig struct {
	// Groups A list of groups that should be displayed in the line chart. Each group can be colored and a matcher can be defined to match the data points that should be part of this group.
	Groups []LineChartWidgetGroup `json:"groups"`

	// ShowSummary If set to `true`, a pie chart will be shown next to the line chart. The pie chart will show the summary of the groups and can be used to filter data points in the line chart.
	ShowSummary *bool `json:"showSummary,omitempty"`
}

LineChartWidgetGroupingConfig Optional configuration to group some data points in the line chart. Groups can be colored and a summary can be shown in an Pie chart next to the line chart.

type LineChartWidgetIdentityConfig added in v2.9.4

type LineChartWidgetIdentityConfig struct {
	// From The name of a metric field containing a unique identifier per desired line chart within the UI.
	From string `json:"from"`

	// MetricName The name of the metrics that should be considered for this line chart.
	MetricName string `json:"metricName"`

	// Mode If there are multiple values by evaluating `from`, how should the widgets be rendered?
	//  - `com.steadybit.widget.line_chart.identity_mode.select` - A single widget is rendered and the user can select the value that should be displayed in the widget.
	//  - `com.steadybit.widget.line_chart.identity_mode.widget-per-value` - A separate widget is rendered per given value.
	Mode LineChartWidgetIdentityConfigMode `json:"mode"`
}

LineChartWidgetIdentityConfig defines model for LineChartWidgetIdentityConfig.

type LineChartWidgetIdentityConfigMode added in v2.9.4

type LineChartWidgetIdentityConfigMode string

LineChartWidgetIdentityConfigMode If there are multiple values by evaluating `from`, how should the widgets be rendered?

  • `com.steadybit.widget.line_chart.identity_mode.select` - A single widget is rendered and the user can select the value that should be displayed in the widget.
  • `com.steadybit.widget.line_chart.identity_mode.widget-per-value` - A separate widget is rendered per given value.
const (
	ComSteadybitWidgetLineChartIdentityModeSelect         LineChartWidgetIdentityConfigMode = "com.steadybit.widget.line_chart.identity_mode.select"
	ComSteadybitWidgetLineChartIdentityModeWidgetPerValue LineChartWidgetIdentityConfigMode = "com.steadybit.widget.line_chart.identity_mode.widget-per-value"
)

Defines values for LineChartWidgetIdentityConfigMode.

type LineChartWidgetTooltipConfig added in v2.9.4

type LineChartWidgetTooltipConfig struct {
	// AdditionalContent Additional content that should be displayed in the tooltip. This can be used to show additional information about the data points in the line chart.
	AdditionalContent []LineChartWidgetTooltipContent `json:"additionalContent"`

	// MetricValueTitle Optional title of the metric value that should be displayed in the tooltip.
	MetricValueTitle *string `json:"metricValueTitle,omitempty"`

	// MetricValueUnit Optional unit of the metric value that should be displayed in the tooltip.
	MetricValueUnit *string `json:"metricValueUnit,omitempty"`
}

LineChartWidgetTooltipConfig defines model for LineChartWidgetTooltipConfig.

type LineChartWidgetTooltipContent added in v2.9.4

type LineChartWidgetTooltipContent struct {
	// From The name of a metric field containing the value for this additional content.
	From string `json:"from"`

	// Title The title of the additional content. This will be displayed as caption for the value in the tooltip.
	Title string `json:"title"`

	// Unit Optional unit which should be added next to the value in the tooltip.
	Unit *string `json:"unit,omitempty"`
}

LineChartWidgetTooltipContent defines model for LineChartWidgetTooltipContent.

type LineChartWidgetType added in v2.9.4

type LineChartWidgetType string

LineChartWidgetType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLineChart`.

const (
	ComSteadybitWidgetLineChart LineChartWidgetType = "com.steadybit.widget.line_chart"
)

Defines values for LineChartWidgetType.

type LogWidget added in v2.3.0

type LogWidget struct {
	// LogType The type of messages that should be displayed in the widget. Needs to match `type` in `action_kit_api.Message`.
	LogType string `json:"logType"`

	// Title The title of the widget. This will be displayed in the widget header.
	Title string `json:"title"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLog`.
	Type LogWidgetType `json:"type"`
}

LogWidget A widget that shows log messages.

type LogWidgetType added in v2.3.0

type LogWidgetType string

LogWidgetType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetLog`.

const (
	ComSteadybitWidgetLog LogWidgetType = "com.steadybit.widget.log"
)

Defines values for LogWidgetType.

type MarkdownWidget added in v2.9.3

type MarkdownWidget struct {
	// Append If set to `true`, the widget will append the content to the existing content of previous endpoint calls. For example, you can return some headings in the `start` call, append some progress information in the `status` calls and add a summary in the `stop` call. If set to `false`, the widget will only show the last submitted content batch, grouped by `timestamp`. Older content will be displayed, when clicking on the timeline in the run view. To improve the performance, you should only return messages if the content has changed compared to the previous batch.
	Append bool `json:"append"`

	// MessageType The type of messages that should be displayed in the widget. Needs to match `type` in `action_kit_api.Message`.
	MessageType string `json:"messageType"`

	// Title The title of the widget. This will be displayed in the widget header.
	Title string `json:"title"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetMarkdown`.
	Type MarkdownWidgetType `json:"type"`
}

MarkdownWidget A widget that renders Markdown content.

type MarkdownWidgetType added in v2.9.3

type MarkdownWidgetType string

MarkdownWidgetType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetMarkdown`.

const (
	ComSteadybitWidgetMarkdown MarkdownWidgetType = "com.steadybit.widget.markdown"
)

Defines values for MarkdownWidgetType.

type Message

type Message struct {
	// Fields Any kind of action specific fields that will be rendered in the platform tooltip of LogWidget
	Fields    *MessageFields `json:"fields,omitempty"`
	Level     *MessageLevel  `json:"level,omitempty"`
	Message   string         `json:"message"`
	Timestamp *time.Time     `json:"timestamp,omitempty"`

	// TimestampSource Source of the timestamp. This is useful when the timestamp is retrieved from some other system. If not specified or equals `extension` the agent will adjust the timestamp with an offset calculated from the response date header and the platform's current time.
	TimestampSource *TimestampSource `json:"timestampSource,omitempty"`
	Type            *string          `json:"type,omitempty"`
}

Message Log-message that will be passed to the platform (default agent log).

type MessageFields added in v2.3.0

type MessageFields map[string]string

MessageFields Any kind of action specific fields that will be rendered in the platform tooltip of LogWidget

type MessageLevel

type MessageLevel string

MessageLevel defines model for Message.Level.

const (
	Debug MessageLevel = "debug"
	Error MessageLevel = "error"
	Info  MessageLevel = "info"
	Warn  MessageLevel = "warn"
)

Defines values for MessageLevel.

type Messages

type Messages = []Message

Messages Log-messages that will be passed to the platform (default agent log).

type Metric

type Metric struct {
	// Metric Key/value pairs describing the metric. This type is modeled after Prometheus' data model, i.e., metric labels. You may encode the metric name as `__name__` similar to how Prometheus does it.
	Metric map[string]string `json:"metric"`

	// Name Metric name. You can alternatively encode the metric name as `__name__` within the metric property.
	Name *string `json:"name,omitempty"`

	// Timestamp Timestamp describing at which moment the value was observed.
	Timestamp time.Time `json:"timestamp"`

	// TimestampSource Source of the timestamp. This is useful when the timestamp is retrieved from some other system. If not specified or equals `extension` the agent will adjust the timestamp with an offset calculated from the response date header and the platform's current time.
	TimestampSource *TimestampSource `json:"timestampSource,omitempty"`
	Value           float64          `json:"value"`
}

Metric Metrics can be exposed by actions. These metrics can then be leveraged by end-users to inspect system behavior and to optionally abort experiment execution when certain metrics are observed, i.e., metrics can act as (steady state) checks.

type Metrics

type Metrics = []Metric

Metrics defines model for Metrics.

type MetricsConfiguration

type MetricsConfiguration struct {
	Query *MetricsQueryConfiguration `json:"query,omitempty"`
}

MetricsConfiguration defines model for MetricsConfiguration.

type MetricsQueryConfiguration

type MetricsQueryConfiguration struct {
	// Endpoint HTTP endpoint which the Steadybit platform/agent could communicate with.
	Endpoint   MutatingEndpointReferenceWithCallInterval `json:"endpoint"`
	Parameters []ActionParameter                         `json:"parameters"`
}

MetricsQueryConfiguration defines model for MetricsQueryConfiguration.

type MutatingEndpointReference

type MutatingEndpointReference struct {
	Method MutatingHttpMethod `json:"method"`

	// Path Absolute path of the HTTP endpoint.
	Path string `json:"path"`
}

MutatingEndpointReference HTTP endpoint which the Steadybit platform/agent could communicate with.

type MutatingEndpointReferenceWithCallInterval

type MutatingEndpointReferenceWithCallInterval struct {
	// CallInterval At what frequency should the state endpoint be called? Takes durations in the format of `100ms` or `10s`.
	CallInterval *string            `json:"callInterval,omitempty"`
	Method       MutatingHttpMethod `json:"method"`

	// Path Absolute path of the HTTP endpoint.
	Path string `json:"path"`
}

MutatingEndpointReferenceWithCallInterval defines model for MutatingEndpointReferenceWithCallInterval.

type MutatingHttpMethod

type MutatingHttpMethod string

MutatingHttpMethod defines model for MutatingHttpMethod.

const (
	DELETE MutatingHttpMethod = "DELETE"
	POST   MutatingHttpMethod = "POST"
	PUT    MutatingHttpMethod = "PUT"
)

Defines values for MutatingHttpMethod.

type ParameterOption

type ParameterOption interface{}

type ParameterOptionsFromTargetAttribute

type ParameterOptionsFromTargetAttribute struct {
	// Attribute Target attribute key from which the possible parameter options are gathered.
	Attribute string `json:"attribute"`
}

ParameterOptionsFromTargetAttribute A meta option that represents all target attribute values for the key defined through the attribute field.

type PredefinedWidget added in v2.3.0

type PredefinedWidget struct {
	PredefinedWidgetId string `json:"predefinedWidgetId"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetPredefined`.
	Type PredefinedWidgetType `json:"type"`
}

PredefinedWidget The platform contains a set of hand crafted predefined widgets. This widget type allows to use one of them.

type PredefinedWidgetType added in v2.3.0

type PredefinedWidgetType string

PredefinedWidgetType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetPredefined`.

const (
	ComSteadybitWidgetPredefined PredefinedWidgetType = "com.steadybit.widget.predefined"
)

Defines values for PredefinedWidgetType.

type PrepareActionRequestBody

type PrepareActionRequestBody struct {
	// Config The action configuration. This contains the end-user configuration done for the action. Possible configuration parameters are defined through the action description.
	Config map[string]interface{} `json:"config"`

	// ExecutionContext The execution context contains information about the current execution of the action.
	ExecutionContext *ExecutionContext `json:"executionContext,omitempty"`
	ExecutionId      uuid.UUID         `json:"executionId"`

	// Target The target on which to act on as identified by a discovery.
	Target *Target `json:"target,omitempty"`
}

PrepareActionRequestBody defines model for PrepareActionRequestBody.

type PrepareActionResponse

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

PrepareActionResponse defines model for PrepareActionResponse.

func (PrepareActionResponse) AsActionKitError

func (t PrepareActionResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the PrepareActionResponse as a ActionKitError

func (PrepareActionResponse) AsPrepareResult

func (t PrepareActionResponse) AsPrepareResult() (PrepareResult, error)

AsPrepareResult returns the union data inside the PrepareActionResponse as a PrepareResult

func (*PrepareActionResponse) FromActionKitError

func (t *PrepareActionResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the PrepareActionResponse as the provided ActionKitError

func (*PrepareActionResponse) FromPrepareResult

func (t *PrepareActionResponse) FromPrepareResult(v PrepareResult) error

FromPrepareResult overwrites any union data inside the PrepareActionResponse as the provided PrepareResult

func (PrepareActionResponse) MarshalJSON

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

func (*PrepareActionResponse) MergeActionKitError added in v2.6.4

func (t *PrepareActionResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the PrepareActionResponse, using the provided ActionKitError

func (*PrepareActionResponse) MergePrepareResult added in v2.6.4

func (t *PrepareActionResponse) MergePrepareResult(v PrepareResult) error

MergePrepareResult performs a merge with any union data inside the PrepareActionResponse, using the provided PrepareResult

func (*PrepareActionResponse) UnmarshalJSON

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

type PrepareResult

type PrepareResult struct {
	Artifacts *Artifacts `json:"artifacts,omitempty"`

	// Error An enhanced version of RFC 7807 Problem Details for HTTP APIs compliant response body for error scenarios
	Error *ActionKitError `json:"error,omitempty"`

	// Messages Log-messages that will be passed to the platform (default agent log).
	Messages *Messages `json:"messages,omitempty"`
	Metrics  *Metrics  `json:"metrics,omitempty"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State ActionState `json:"state"`
}

PrepareResult defines model for PrepareResult.

type QueryMetricsRequestBody

type QueryMetricsRequestBody struct {
	// Config The metric query configuration. This contains the end-user configuration done for the action. Possible configuration parameters are defined through the action description.
	Config      map[string]interface{} `json:"config"`
	ExecutionId uuid.UUID              `json:"executionId"`

	// Target The target on which to act on as identified by a discovery.
	Target *Target `json:"target,omitempty"`

	// Timestamp For what timestamp the metric values should be retrieved.
	Timestamp time.Time `json:"timestamp"`
}

QueryMetricsRequestBody defines model for QueryMetricsRequestBody.

type QueryMetricsResponse

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

QueryMetricsResponse defines model for QueryMetricsResponse.

func (QueryMetricsResponse) AsActionKitError

func (t QueryMetricsResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the QueryMetricsResponse as a ActionKitError

func (QueryMetricsResponse) AsQueryMetricsResult

func (t QueryMetricsResponse) AsQueryMetricsResult() (QueryMetricsResult, error)

AsQueryMetricsResult returns the union data inside the QueryMetricsResponse as a QueryMetricsResult

func (*QueryMetricsResponse) FromActionKitError

func (t *QueryMetricsResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the QueryMetricsResponse as the provided ActionKitError

func (*QueryMetricsResponse) FromQueryMetricsResult

func (t *QueryMetricsResponse) FromQueryMetricsResult(v QueryMetricsResult) error

FromQueryMetricsResult overwrites any union data inside the QueryMetricsResponse as the provided QueryMetricsResult

func (QueryMetricsResponse) MarshalJSON

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

func (*QueryMetricsResponse) MergeActionKitError added in v2.6.4

func (t *QueryMetricsResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the QueryMetricsResponse, using the provided ActionKitError

func (*QueryMetricsResponse) MergeQueryMetricsResult added in v2.6.4

func (t *QueryMetricsResponse) MergeQueryMetricsResult(v QueryMetricsResult) error

MergeQueryMetricsResult performs a merge with any union data inside the QueryMetricsResponse, using the provided QueryMetricsResult

func (*QueryMetricsResponse) UnmarshalJSON

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

type QueryMetricsResult

type QueryMetricsResult struct {
	Artifacts *Artifacts `json:"artifacts,omitempty"`

	// Messages Log-messages that will be passed to the platform (default agent log).
	Messages *Messages `json:"messages,omitempty"`
	Metrics  *Metrics  `json:"metrics,omitempty"`
}

QueryMetricsResult defines model for QueryMetricsResult.

type ReadHttpMethod added in v2.8.0

type ReadHttpMethod string

ReadHttpMethod defines model for ReadHttpMethod.

const (
	GET ReadHttpMethod = "GET"
)

Defines values for ReadHttpMethod.

type RestrictedEndpoint added in v2.6.0

type RestrictedEndpoint struct {
	// Cidr A CIDR that is used to restrict the target selection to a specific network.
	Cidr string `json:"cidr"`

	// Name The name of the protected Endpoint. For reference/debugging purposes only.
	Name string `json:"name"`

	// PortMax The maximum port number that is allowed to be used for the Endpoint.
	PortMax int `json:"portMax"`

	// PortMin The minimum port number that is allowed to be used for the Endpoint.
	PortMin int `json:"portMin"`

	// Url The URL of the protected Endpoint.
	Url string `json:"url"`
}

RestrictedEndpoint defines model for RestrictedEndpoint.

type StartActionRequestBody

type StartActionRequestBody struct {
	ExecutionId uuid.UUID `json:"executionId"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State ActionState `json:"state"`
}

StartActionRequestBody defines model for StartActionRequestBody.

type StartActionResponse

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

StartActionResponse defines model for StartActionResponse.

func (StartActionResponse) AsActionKitError

func (t StartActionResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the StartActionResponse as a ActionKitError

func (StartActionResponse) AsStartResult

func (t StartActionResponse) AsStartResult() (StartResult, error)

AsStartResult returns the union data inside the StartActionResponse as a StartResult

func (*StartActionResponse) FromActionKitError

func (t *StartActionResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the StartActionResponse as the provided ActionKitError

func (*StartActionResponse) FromStartResult

func (t *StartActionResponse) FromStartResult(v StartResult) error

FromStartResult overwrites any union data inside the StartActionResponse as the provided StartResult

func (StartActionResponse) MarshalJSON

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

func (*StartActionResponse) MergeActionKitError added in v2.6.4

func (t *StartActionResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the StartActionResponse, using the provided ActionKitError

func (*StartActionResponse) MergeStartResult added in v2.6.4

func (t *StartActionResponse) MergeStartResult(v StartResult) error

MergeStartResult performs a merge with any union data inside the StartActionResponse, using the provided StartResult

func (*StartActionResponse) UnmarshalJSON

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

type StartResult

type StartResult struct {
	Artifacts *Artifacts `json:"artifacts,omitempty"`

	// Error An enhanced version of RFC 7807 Problem Details for HTTP APIs compliant response body for error scenarios
	Error *ActionKitError `json:"error,omitempty"`

	// Messages Log-messages that will be passed to the platform (default agent log).
	Messages *Messages `json:"messages,omitempty"`
	Metrics  *Metrics  `json:"metrics,omitempty"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State *ActionState `json:"state,omitempty"`
}

StartResult defines model for StartResult.

type StateOverTimeWidget added in v2.2.0

type StateOverTimeWidget struct {
	Identity StateOverTimeWidgetIdentityConfig `json:"identity"`
	Label    StateOverTimeWidgetLabelConfig    `json:"label"`
	State    StateOverTimeWidgetStateConfig    `json:"state"`

	// Title The title of the widget. This will be displayed in the widget header.
	Title   string                           `json:"title"`
	Tooltip StateOverTimeWidgetTooltipConfig `json:"tooltip"`

	// Type The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetStateOverTime`.
	Type  StateOverTimeWidgetType         `json:"type"`
	Url   *StateOverTimeWidgetUrlConfig   `json:"url,omitempty"`
	Value *StateOverTimeWidgetValueConfig `json:"value,omitempty"`
}

StateOverTimeWidget A widget that shows a state of over time.

type StateOverTimeWidgetIdentityConfig added in v2.2.0

type StateOverTimeWidgetIdentityConfig struct {
	// From The name of a metric field containing a unique identifier per desired chart row within the UI.
	From string `json:"from"`
}

StateOverTimeWidgetIdentityConfig defines model for StateOverTimeWidgetIdentityConfig.

type StateOverTimeWidgetLabelConfig added in v2.2.0

type StateOverTimeWidgetLabelConfig struct {
	// From The name of a metric field containing a human-readable label per desired chart row within the UI.
	From string `json:"from"`
}

StateOverTimeWidgetLabelConfig defines model for StateOverTimeWidgetLabelConfig.

type StateOverTimeWidgetStateConfig added in v2.2.0

type StateOverTimeWidgetStateConfig struct {
	// From The name of a metric field containing the current state at any time.
	From string `json:"from"`
}

StateOverTimeWidgetStateConfig defines model for StateOverTimeWidgetStateConfig.

type StateOverTimeWidgetTooltipConfig added in v2.2.0

type StateOverTimeWidgetTooltipConfig struct {
	// From The name of a metric field containing the current tooltip at any time.
	From string `json:"from"`
}

StateOverTimeWidgetTooltipConfig defines model for StateOverTimeWidgetTooltipConfig.

type StateOverTimeWidgetType added in v2.2.0

type StateOverTimeWidgetType string

StateOverTimeWidgetType The type of the widget. Needs to be set to `action_kit_api.ComSteadybitWidgetStateOverTime`.

const (
	ComSteadybitWidgetStateOverTime StateOverTimeWidgetType = "com.steadybit.widget.state_over_time"
)

Defines values for StateOverTimeWidgetType.

type StateOverTimeWidgetUrlConfig added in v2.2.0

type StateOverTimeWidgetUrlConfig struct {
	// From The name of a metric field containing a URL. When available, it causes a chart segment to turn into a hyperlink.
	From *string `json:"from,omitempty"`
}

StateOverTimeWidgetUrlConfig defines model for StateOverTimeWidgetUrlConfig.

type StateOverTimeWidgetValueConfig added in v2.2.0

type StateOverTimeWidgetValueConfig struct {
	// Hide Set to true to hide the metric value within the widget. This is useful when only the translated state information is relevant.
	Hide *bool `json:"hide,omitempty"`
}

StateOverTimeWidgetValueConfig defines model for StateOverTimeWidgetValueConfig.

type StatusResult

type StatusResult struct {
	Artifacts *Artifacts `json:"artifacts,omitempty"`

	// Completed the agent will continue to poll the status endpoint as long as completed is false and no error is set
	Completed bool `json:"completed"`

	// Error An enhanced version of RFC 7807 Problem Details for HTTP APIs compliant response body for error scenarios
	Error *ActionKitError `json:"error,omitempty"`

	// Messages Log-messages that will be passed to the platform (default agent log).
	Messages *Messages `json:"messages,omitempty"`
	Metrics  *Metrics  `json:"metrics,omitempty"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State *ActionState `json:"state,omitempty"`
}

StatusResult defines model for StatusResult.

type StopActionRequestBody

type StopActionRequestBody struct {
	ExecutionId uuid.UUID `json:"executionId"`

	// State Any kind of action specific state that will be passed to the next endpoints.
	State ActionState `json:"state"`
}

StopActionRequestBody defines model for StopActionRequestBody.

type StopActionResponse

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

StopActionResponse defines model for StopActionResponse.

func (StopActionResponse) AsActionKitError

func (t StopActionResponse) AsActionKitError() (ActionKitError, error)

AsActionKitError returns the union data inside the StopActionResponse as a ActionKitError

func (StopActionResponse) AsStopResult

func (t StopActionResponse) AsStopResult() (StopResult, error)

AsStopResult returns the union data inside the StopActionResponse as a StopResult

func (*StopActionResponse) FromActionKitError

func (t *StopActionResponse) FromActionKitError(v ActionKitError) error

FromActionKitError overwrites any union data inside the StopActionResponse as the provided ActionKitError

func (*StopActionResponse) FromStopResult

func (t *StopActionResponse) FromStopResult(v StopResult) error

FromStopResult overwrites any union data inside the StopActionResponse as the provided StopResult

func (StopActionResponse) MarshalJSON

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

func (*StopActionResponse) MergeActionKitError added in v2.6.4

func (t *StopActionResponse) MergeActionKitError(v ActionKitError) error

MergeActionKitError performs a merge with any union data inside the StopActionResponse, using the provided ActionKitError

func (*StopActionResponse) MergeStopResult added in v2.6.4

func (t *StopActionResponse) MergeStopResult(v StopResult) error

MergeStopResult performs a merge with any union data inside the StopActionResponse, using the provided StopResult

func (*StopActionResponse) UnmarshalJSON

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

type StopResult

type StopResult struct {
	Artifacts *Artifacts `json:"artifacts,omitempty"`

	// Error An enhanced version of RFC 7807 Problem Details for HTTP APIs compliant response body for error scenarios
	Error *ActionKitError `json:"error,omitempty"`

	// Messages Log-messages that will be passed to the platform (default agent log).
	Messages *Messages `json:"messages,omitempty"`
	Metrics  *Metrics  `json:"metrics,omitempty"`
}

StopResult defines model for StopResult.

type Target

type Target struct {
	// Attributes These attributes include detailed information about the target provided through the discovery. These attributes are typically used as additional parameters within the action implementation.
	Attributes map[string][]string `json:"attributes"`
	Name       string              `json:"name"`
}

Target The target on which to act on as identified by a discovery.

type TargetSelection added in v2.5.0

type TargetSelection struct {
	// DefaultBlastRadius The default blast radius configuration for the action. (Default: 100 percent)
	DefaultBlastRadius *DefaultBlastRadius `json:"defaultBlastRadius,omitempty"`

	// MissingQuerySelection The default selection of the targets in the UI if no query is provided by the user. * 'include_all' All targets will be selected by default * 'include_none' (default) No targets will be selected by default
	MissingQuerySelection *TargetSelectionMissingQuerySelection `json:"missingQuerySelection,omitempty"`

	// QuantityRestriction How many targets should be selected by the user. Values:
	//  * `exactly_one` - Exactly one target must be selected. The execution will fail if more than one target is selected.
	//  * `all` - All selected targets will be used. The ui will not show a percentage randomizer for the target selection.
	//  * `none` - Default. There are no restriction in place for the number of targets. The ui will show a percentage randomizer for the target selection.
	QuantityRestriction *TargetSelectionQuantityRestriction `json:"quantityRestriction,omitempty"`

	// SelectionTemplates Users that want to configure an action with a targetType need to define a target selection through the query UI or query language. Extensions can define selection templates to help users define such target selections.
	SelectionTemplates *TargetSelectionTemplates `json:"selectionTemplates,omitempty"`

	// TargetType What target type this action should be offered for. Matches the `id` field within `DescribeTargetTypeResponse` within DiscoveryKit.
	TargetType string `json:"targetType"`
}

TargetSelection Used to specify various aspects of the target selection. If the action don't need a target selection, this field can be omitted.

type TargetSelectionMissingQuerySelection added in v2.9.5

type TargetSelectionMissingQuerySelection string

TargetSelectionMissingQuerySelection The default selection of the targets in the UI if no query is provided by the user. * 'include_all' All targets will be selected by default * 'include_none' (default) No targets will be selected by default

const (
	MissingQuerySelectionIncludeAll  TargetSelectionMissingQuerySelection = "include_all"
	MissingQuerySelectionIncludeNone TargetSelectionMissingQuerySelection = "include_none"
)

Defines values for TargetSelectionMissingQuerySelection.

type TargetSelectionQuantityRestriction added in v2.5.0

type TargetSelectionQuantityRestriction string

TargetSelectionQuantityRestriction How many targets should be selected by the user. Values:

  • `exactly_one` - Exactly one target must be selected. The execution will fail if more than one target is selected.
  • `all` - All selected targets will be used. The ui will not show a percentage randomizer for the target selection.
  • `none` - Default. There are no restriction in place for the number of targets. The ui will show a percentage randomizer for the target selection.
const (
	QuantityRestrictionAll        TargetSelectionQuantityRestriction = "all"
	QuantityRestrictionExactlyOne TargetSelectionQuantityRestriction = "exactly_one"
	QuantityRestrictionNone       TargetSelectionQuantityRestriction = "none"
)

Defines values for TargetSelectionQuantityRestriction.

type TargetSelectionTemplate added in v2.1.0

type TargetSelectionTemplate struct {
	// Description Longer target selection template description. For example, to explain the template's purpose.
	Description *string `json:"description,omitempty"`

	// Label Human-readable short label.
	Label string `json:"label"`

	// Query The target selection query is defined using Steadybit's query language. For example:
	//   aws.account="" AND aws.zone.id=""
	// For more information about the query language, please inspect Steadybit's documentation:
	//   https://docs.steadybit.com/use-steadybit/query-language
	Query string `json:"query"`
}

TargetSelectionTemplate defines model for TargetSelectionTemplate.

type TargetSelectionTemplates added in v2.1.0

type TargetSelectionTemplates = []TargetSelectionTemplate

TargetSelectionTemplates Users that want to configure an action with a targetType need to define a target selection through the query UI or query language. Extensions can define selection templates to help users define such target selections.

type TimeControl added in v2.7.0

type TimeControl string

TimeControl Actions can either be an instantaneous event, e.g., the restart of a host, or an activity spanning over an unspecified duration. For those actions having a duration, we differentiate between internally, e.g., waiting for a deployment to finish, and externally, e.g., waiting for a user-specified time to pass, controlled durations.

const (
	TimeControlExternal      TimeControl = "external"
	TimeControlInstantaneous TimeControl = "instantaneous"
	TimeControlInternal      TimeControl = "internal"
)

Defines values for TimeControl.

type TimestampSource added in v2.6.4

type TimestampSource string

TimestampSource Source of the timestamp. This is useful when the timestamp is retrieved from some other system. If not specified or equals `extension` the agent will adjust the timestamp with an offset calculated from the response date header and the platform's current time.

const (
	TimestampSourceExtension TimestampSource = "extension"
	TimestampSourceExternal  TimestampSource = "external"
)

Defines values for TimestampSource.

type Widget added in v2.2.0

type Widget interface{}

type Widgets added in v2.2.0

type Widgets = []Widget

Widgets Widgets that will be rendered in the experiment result view after an experiment has finished.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL