api

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

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

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

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewConsoleEventsRequest

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

NewConsoleEventsRequest generates requests for ConsoleEvents

func NewGraphGoalsRequest

func NewGraphGoalsRequest(server string, params *GraphGoalsParams, body GraphGoalsJSONRequestBody) (*http.Request, error)

NewGraphGoalsRequest calls the generic GraphGoals builder with application/json body

func NewGraphGoalsRequestWithBody

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

NewGraphGoalsRequestWithBody generates requests for GraphGoals with any type of body

func NewGraphNeighborsRequest

func NewGraphNeighborsRequest(server string, params *GraphNeighborsParams, body GraphNeighborsJSONRequestBody) (*http.Request, error)

NewGraphNeighborsRequest calls the generic GraphNeighbors builder with application/json body

func NewGraphNeighborsRequestWithBody

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

NewGraphNeighborsRequestWithBody generates requests for GraphNeighbors with any type of body

func NewGraphNeighboursRequest

func NewGraphNeighboursRequest(server string, params *GraphNeighboursParams, body GraphNeighboursJSONRequestBody) (*http.Request, error)

NewGraphNeighboursRequest calls the generic GraphNeighbours builder with application/json body

func NewGraphNeighboursRequestWithBody

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

NewGraphNeighboursRequestWithBody generates requests for GraphNeighbours with any type of body

func NewListDomainClassesRequest

func NewListDomainClassesRequest(server string, domain string) (*http.Request, error)

NewListDomainClassesRequest generates requests for ListDomainClasses

func NewListDomainsRequest

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

NewListDomainsRequest generates requests for ListDomains

func NewListGoalsRequest

func NewListGoalsRequest(server string, body ListGoalsJSONRequestBody) (*http.Request, error)

NewListGoalsRequest calls the generic ListGoals builder with application/json body

func NewListGoalsRequestWithBody

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

NewListGoalsRequestWithBody generates requests for ListGoals with any type of body

func NewObjectsRequest

func NewObjectsRequest(server string, params *ObjectsParams) (*http.Request, error)

NewObjectsRequest generates requests for Objects

func NewSetConfigRequest

func NewSetConfigRequest(server string, params *SetConfigParams) (*http.Request, error)

NewSetConfigRequest generates requests for SetConfig

func NewSetConsoleRequest

func NewSetConsoleRequest(server string, body SetConsoleJSONRequestBody) (*http.Request, error)

NewSetConsoleRequest calls the generic SetConsole builder with application/json body

func NewSetConsoleRequestWithBody

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

NewSetConsoleRequestWithBody generates requests for SetConsole with any type of body

Types

type Class

type Class = string

Class Full name of a class of data, format is DOMAIN:CLASS. DOMAIN: name of a domain (e.g. k8s, log, metric, alert, trace, netflow). CLASS: name within the domain.

type Client

type Client struct {
	// The endpoint of the server conforming to this interface, with scheme,
	// https://api.deepmap.com for example. This can contain a path relative
	// to the server, such as https://api.deepmap.com/dev-test, and all the
	// paths in the swagger spec will be appended to the server.
	Server string

	// Doer for performing requests, typically a *http.Client with any
	// customized settings, such as certificate chains.
	Client HttpRequestDoer

	// A list of callbacks for modifying requests which are generated before sending over
	// the network.
	RequestEditors []RequestEditorFn
}

Client which conforms to the OpenAPI3 specification for this service.

func NewClient

func NewClient(server string, opts ...ClientOption) (*Client, error)

Creates a new Client, with reasonable defaults

func (*Client) ConsoleEvents

func (c *Client) ConsoleEvents(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphGoals

func (c *Client) GraphGoals(ctx context.Context, params *GraphGoalsParams, body GraphGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphGoalsWithBody

func (c *Client) GraphGoalsWithBody(ctx context.Context, params *GraphGoalsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphNeighbors

func (c *Client) GraphNeighbors(ctx context.Context, params *GraphNeighborsParams, body GraphNeighborsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphNeighborsWithBody

func (c *Client) GraphNeighborsWithBody(ctx context.Context, params *GraphNeighborsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphNeighbours

func (c *Client) GraphNeighbours(ctx context.Context, params *GraphNeighboursParams, body GraphNeighboursJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) GraphNeighboursWithBody

func (c *Client) GraphNeighboursWithBody(ctx context.Context, params *GraphNeighboursParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListDomainClasses

func (c *Client) ListDomainClasses(ctx context.Context, domain string, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListDomains

func (c *Client) ListDomains(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListGoals

func (c *Client) ListGoals(ctx context.Context, body ListGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) ListGoalsWithBody

func (c *Client) ListGoalsWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) Objects

func (c *Client) Objects(ctx context.Context, params *ObjectsParams, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) SetConfig

func (c *Client) SetConfig(ctx context.Context, params *SetConfigParams, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) SetConsole

func (c *Client) SetConsole(ctx context.Context, body SetConsoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

func (*Client) SetConsoleWithBody

func (c *Client) SetConsoleWithBody(ctx context.Context, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*http.Response, error)

type ClientInterface

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

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

	SetConsole(ctx context.Context, body SetConsoleJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

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

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

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

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

	GraphGoals(ctx context.Context, params *GraphGoalsParams, body GraphGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

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

	GraphNeighbors(ctx context.Context, params *GraphNeighborsParams, body GraphNeighborsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

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

	GraphNeighbours(ctx context.Context, params *GraphNeighboursParams, body GraphNeighboursJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

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

	ListGoals(ctx context.Context, body ListGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*http.Response, error)

	// Objects request
	Objects(ctx context.Context, params *ObjectsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
}

The interface specification for the client above.

type ClientOption

type ClientOption func(*Client) error

ClientOption allows setting custom parameters during construction

func WithBaseURL

func WithBaseURL(baseURL string) ClientOption

WithBaseURL overrides the baseURL.

func WithHTTPClient

func WithHTTPClient(doer HttpRequestDoer) ClientOption

WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.

func WithRequestEditorFn

func WithRequestEditorFn(fn RequestEditorFn) ClientOption

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

type ClientWithResponses

type ClientWithResponses struct {
	ClientInterface
}

ClientWithResponses builds on ClientInterface to offer response payloads

func NewClientWithResponses

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

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

func (*ClientWithResponses) ConsoleEventsWithResponse

func (c *ClientWithResponses) ConsoleEventsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ConsoleEventsResponse, error)

ConsoleEventsWithResponse request returning *ConsoleEventsResponse

func (*ClientWithResponses) GraphGoalsWithBodyWithResponse

func (c *ClientWithResponses) GraphGoalsWithBodyWithResponse(ctx context.Context, params *GraphGoalsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphGoalsResponse, error)

GraphGoalsWithBodyWithResponse request with arbitrary body returning *GraphGoalsResponse

func (*ClientWithResponses) GraphGoalsWithResponse

func (c *ClientWithResponses) GraphGoalsWithResponse(ctx context.Context, params *GraphGoalsParams, body GraphGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphGoalsResponse, error)

func (*ClientWithResponses) GraphNeighborsWithBodyWithResponse

func (c *ClientWithResponses) GraphNeighborsWithBodyWithResponse(ctx context.Context, params *GraphNeighborsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphNeighborsResponse, error)

GraphNeighborsWithBodyWithResponse request with arbitrary body returning *GraphNeighborsResponse

func (*ClientWithResponses) GraphNeighborsWithResponse

func (c *ClientWithResponses) GraphNeighborsWithResponse(ctx context.Context, params *GraphNeighborsParams, body GraphNeighborsJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphNeighborsResponse, error)

func (*ClientWithResponses) GraphNeighboursWithBodyWithResponse

func (c *ClientWithResponses) GraphNeighboursWithBodyWithResponse(ctx context.Context, params *GraphNeighboursParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphNeighboursResponse, error)

GraphNeighboursWithBodyWithResponse request with arbitrary body returning *GraphNeighboursResponse

func (*ClientWithResponses) GraphNeighboursWithResponse

func (c *ClientWithResponses) GraphNeighboursWithResponse(ctx context.Context, params *GraphNeighboursParams, body GraphNeighboursJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphNeighboursResponse, error)

func (*ClientWithResponses) ListDomainClassesWithResponse

func (c *ClientWithResponses) ListDomainClassesWithResponse(ctx context.Context, domain string, reqEditors ...RequestEditorFn) (*ListDomainClassesResponse, error)

ListDomainClassesWithResponse request returning *ListDomainClassesResponse

func (*ClientWithResponses) ListDomainsWithResponse

func (c *ClientWithResponses) ListDomainsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListDomainsResponse, error)

ListDomainsWithResponse request returning *ListDomainsResponse

func (*ClientWithResponses) ListGoalsWithBodyWithResponse

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

ListGoalsWithBodyWithResponse request with arbitrary body returning *ListGoalsResponse

func (*ClientWithResponses) ListGoalsWithResponse

func (c *ClientWithResponses) ListGoalsWithResponse(ctx context.Context, body ListGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*ListGoalsResponse, error)

func (*ClientWithResponses) ObjectsWithResponse

func (c *ClientWithResponses) ObjectsWithResponse(ctx context.Context, params *ObjectsParams, reqEditors ...RequestEditorFn) (*ObjectsResponse, error)

ObjectsWithResponse request returning *ObjectsResponse

func (*ClientWithResponses) SetConfigWithResponse

func (c *ClientWithResponses) SetConfigWithResponse(ctx context.Context, params *SetConfigParams, reqEditors ...RequestEditorFn) (*SetConfigResponse, error)

SetConfigWithResponse request returning *SetConfigResponse

func (*ClientWithResponses) SetConsoleWithBodyWithResponse

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

SetConsoleWithBodyWithResponse request with arbitrary body returning *SetConsoleResponse

func (*ClientWithResponses) SetConsoleWithResponse

func (c *ClientWithResponses) SetConsoleWithResponse(ctx context.Context, body SetConsoleJSONRequestBody, reqEditors ...RequestEditorFn) (*SetConsoleResponse, error)

type ClientWithResponsesInterface

type ClientWithResponsesInterface interface {
	// SetConfigWithResponse request
	SetConfigWithResponse(ctx context.Context, params *SetConfigParams, reqEditors ...RequestEditorFn) (*SetConfigResponse, error)

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

	SetConsoleWithResponse(ctx context.Context, body SetConsoleJSONRequestBody, reqEditors ...RequestEditorFn) (*SetConsoleResponse, error)

	// ConsoleEventsWithResponse request
	ConsoleEventsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ConsoleEventsResponse, error)

	// ListDomainClassesWithResponse request
	ListDomainClassesWithResponse(ctx context.Context, domain string, reqEditors ...RequestEditorFn) (*ListDomainClassesResponse, error)

	// ListDomainsWithResponse request
	ListDomainsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*ListDomainsResponse, error)

	// GraphGoalsWithBodyWithResponse request with any body
	GraphGoalsWithBodyWithResponse(ctx context.Context, params *GraphGoalsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphGoalsResponse, error)

	GraphGoalsWithResponse(ctx context.Context, params *GraphGoalsParams, body GraphGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphGoalsResponse, error)

	// GraphNeighborsWithBodyWithResponse request with any body
	GraphNeighborsWithBodyWithResponse(ctx context.Context, params *GraphNeighborsParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphNeighborsResponse, error)

	GraphNeighborsWithResponse(ctx context.Context, params *GraphNeighborsParams, body GraphNeighborsJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphNeighborsResponse, error)

	// GraphNeighboursWithBodyWithResponse request with any body
	GraphNeighboursWithBodyWithResponse(ctx context.Context, params *GraphNeighboursParams, contentType string, body io.Reader, reqEditors ...RequestEditorFn) (*GraphNeighboursResponse, error)

	GraphNeighboursWithResponse(ctx context.Context, params *GraphNeighboursParams, body GraphNeighboursJSONRequestBody, reqEditors ...RequestEditorFn) (*GraphNeighboursResponse, error)

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

	ListGoalsWithResponse(ctx context.Context, body ListGoalsJSONRequestBody, reqEditors ...RequestEditorFn) (*ListGoalsResponse, error)

	// ObjectsWithResponse request
	ObjectsWithResponse(ctx context.Context, params *ObjectsParams, reqEditors ...RequestEditorFn) (*ObjectsResponse, error)
}

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

type Console

type Console struct {
	// Search The troubleshooting panel displays the results of this correlation search.
	Search *Search `json:"search,omitempty" jsonschema:"The troubleshooting panel displays the results of this correlation search."`

	// View The main console view displays the results of this query.
	View Query `json:"view,omitempty" jsonschema:"Query for the main console view, in DOMAIN:CLASS:SELECTOR format."`
}

Console State of the user's graphical console display (e.g. OpenShift web console).

type ConsoleEventsResponse

type ConsoleEventsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
}

func ParseConsoleEventsResponse

func ParseConsoleEventsResponse(rsp *http.Response) (*ConsoleEventsResponse, error)

ParseConsoleEventsResponse parses an HTTP response from a ConsoleEventsWithResponse call

func (ConsoleEventsResponse) Status

func (r ConsoleEventsResponse) Status() string

Status returns HTTPResponse.Status

func (ConsoleEventsResponse) StatusCode

func (r ConsoleEventsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Constraint

type Constraint struct {
	// End Ignore objects with timestamps after this end time.
	End *time.Time `json:"end,omitempty" jsonschema:"Ignore objects with timestamps after this end time."`

	// Limit Limit total number of objects per query.
	Limit *int `json:"limit,omitempty" jsonschema:"Limit total number of objects per query."`

	// Start Ignore objects with timestamps before this start time.
	Start *time.Time `json:"start,omitempty" jsonschema:"Ignore objects with timestamps before this start time."`
}

Constraint Constrains the objects that will be included in search results.

type Domain

type Domain struct {
	// Description Brief description of the domain.
	Description string `json:"description,omitempty"`

	// Name Name of the domain.
	Name string `json:"name"`

	// Stores Stores configured for the domain.
	Stores []Store `json:"stores,omitempty"`
}

Domain Domain configuration information.

type Edge

type Edge struct {
	// Goal Class name of the goal node.
	Goal Class `json:"goal" jsonschema:"Class name of the goal node, in DOMAIN:CLASS format."`

	// Rules Set of rules followed along this edge.
	Rules []Rule `json:"rules,omitempty" jsonschema:"Set of rules followed along this edge."`

	// Start Class name of the start node.
	Start Class `json:"start" jsonschema:"Class name of the start node, in DOMAIN:CLASS format."`
}

Edge Directed edge in the result graph, from Start to Goal classes.

type Error

type Error struct {
	// Error Error message.
	Error string `json:"error"`
}

Error Error result containing an error message.

type Goals

type Goals struct {
	// Goals Goal classes in DOMAIN:CLASS format, e.g. log:application, alert:alert
	Goals []Class `json:"goals" jsonschema:"Goal classes in DOMAIN:CLASS format, e.g. log:application, alert:alert."`

	// Start Starting point for the search.
	Start Start `json:"start" jsonschema:"Starting point for the search."`
}

Goals Parameters for a goal-directed correlation search. Finds paths from start objects to goal classes.

type Graph

type Graph struct {
	// Edges List of graph edges.
	Edges []Edge `json:"edges,omitempty" jsonschema:"List of graph edges."`

	// Nodes List of graph nodes.
	Nodes []Node `json:"nodes,omitempty" jsonschema:"List of graph nodes."`
}

Graph Graph resulting from a correlation search.

type GraphGoalsJSONRequestBody

type GraphGoalsJSONRequestBody = Goals

GraphGoalsJSONRequestBody defines body for GraphGoals for application/json ContentType.

type GraphGoalsParams

type GraphGoalsParams struct {
	// Options Options controlling the form of the returned graph.
	Options *GraphOptions `form:"options,omitempty" json:"options,omitempty"`
}

GraphGoalsParams defines parameters for GraphGoals.

type GraphGoalsResponse

type GraphGoalsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Graph
	JSON400      *Error
	JSON404      *Error
}

func ParseGraphGoalsResponse

func ParseGraphGoalsResponse(rsp *http.Response) (*GraphGoalsResponse, error)

ParseGraphGoalsResponse parses an HTTP response from a GraphGoalsWithResponse call

func (GraphGoalsResponse) Status

func (r GraphGoalsResponse) Status() string

Status returns HTTPResponse.Status

func (GraphGoalsResponse) StatusCode

func (r GraphGoalsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GraphNeighborsJSONRequestBody

type GraphNeighborsJSONRequestBody = Neighbors

GraphNeighborsJSONRequestBody defines body for GraphNeighbors for application/json ContentType.

type GraphNeighborsParams

type GraphNeighborsParams struct {
	// Options Options controlling the form of the returned graph.
	Options *GraphOptions `form:"options,omitempty" json:"options,omitempty"`
}

GraphNeighborsParams defines parameters for GraphNeighbors.

type GraphNeighborsResponse

type GraphNeighborsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Graph
	JSON400      *Error
	JSON404      *Error
}

func ParseGraphNeighborsResponse

func ParseGraphNeighborsResponse(rsp *http.Response) (*GraphNeighborsResponse, error)

ParseGraphNeighborsResponse parses an HTTP response from a GraphNeighborsWithResponse call

func (GraphNeighborsResponse) Status

func (r GraphNeighborsResponse) Status() string

Status returns HTTPResponse.Status

func (GraphNeighborsResponse) StatusCode

func (r GraphNeighborsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GraphNeighboursJSONRequestBody

type GraphNeighboursJSONRequestBody = Neighbors

GraphNeighboursJSONRequestBody defines body for GraphNeighbours for application/json ContentType.

type GraphNeighboursParams

type GraphNeighboursParams struct {
	// Options Options controlling the form of the returned graph.
	Options *GraphOptions `form:"options,omitempty" json:"options,omitempty"`
}

GraphNeighboursParams defines parameters for GraphNeighbours.

type GraphNeighboursResponse

type GraphNeighboursResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *Graph
	JSON400      *Error
	JSON404      *Error
}

func ParseGraphNeighboursResponse

func ParseGraphNeighboursResponse(rsp *http.Response) (*GraphNeighboursResponse, error)

ParseGraphNeighboursResponse parses an HTTP response from a GraphNeighboursWithResponse call

func (GraphNeighboursResponse) Status

func (r GraphNeighboursResponse) Status() string

Status returns HTTPResponse.Status

func (GraphNeighboursResponse) StatusCode

func (r GraphNeighboursResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type GraphOptions

type GraphOptions struct {
	// Errors If true include non-fatal error messages.
	Errors *bool `json:"errors,omitempty" jsonschema:"If true include non-fatal error messages."`

	// Results If true include full JSON results with each Query.
	Results *bool `json:"results,omitempty" jsonschema:"If true include full JSON results with each Query."`

	// Rules If true include rule names in graph edges.
	Rules *bool `json:"rules,omitempty" jsonschema:"If true include rule names in graph edges."`
}

GraphOptions Options controlling the form of the returned graph.

type HttpRequestDoer

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

Doer performs HTTP requests.

The standard http.Client implements this interface.

type ListDomainClassesResponse

type ListDomainClassesResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]string
	JSON400      *Error
	JSON404      *Error
}

func ParseListDomainClassesResponse

func ParseListDomainClassesResponse(rsp *http.Response) (*ListDomainClassesResponse, error)

ParseListDomainClassesResponse parses an HTTP response from a ListDomainClassesWithResponse call

func (ListDomainClassesResponse) Status

func (r ListDomainClassesResponse) Status() string

Status returns HTTPResponse.Status

func (ListDomainClassesResponse) StatusCode

func (r ListDomainClassesResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type ListDomainsResponse

type ListDomainsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]Domain
	JSON400      *Error
	JSON404      *Error
}

func ParseListDomainsResponse

func ParseListDomainsResponse(rsp *http.Response) (*ListDomainsResponse, error)

ParseListDomainsResponse parses an HTTP response from a ListDomainsWithResponse call

func (ListDomainsResponse) Status

func (r ListDomainsResponse) Status() string

Status returns HTTPResponse.Status

func (ListDomainsResponse) StatusCode

func (r ListDomainsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type ListGoalsJSONRequestBody

type ListGoalsJSONRequestBody = Goals

ListGoalsJSONRequestBody defines body for ListGoals for application/json ContentType.

type ListGoalsResponse

type ListGoalsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]Node
	JSON400      *Error
	JSON404      *Error
}

func ParseListGoalsResponse

func ParseListGoalsResponse(rsp *http.Response) (*ListGoalsResponse, error)

ParseListGoalsResponse parses an HTTP response from a ListGoalsWithResponse call

func (ListGoalsResponse) Status

func (r ListGoalsResponse) Status() string

Status returns HTTPResponse.Status

func (ListGoalsResponse) StatusCode

func (r ListGoalsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Neighbors

type Neighbors struct {
	// Depth Maximum number of correlation steps to follow from the start. Depth 1 returns direct correlations only.
	Depth int `` /* 129-byte string literal not displayed */

	// Start Starting point for the search.
	Start Start `json:"start" jsonschema:"Starting point for the search."`
}

Neighbors Parameters for a neighborhood correlation search. Finds all objects reachable from the start by following correlation rules up to the maximum depth.

type Node

type Node struct {
	// Class Full class name.
	Class string `json:"class" jsonschema:"Full class name in DOMAIN:CLASS format."`

	// Count Number of results for this class, after de-duplication.
	Count *int `json:"count,omitempty" jsonschema:"Number of results for this class, after de-duplication."`

	// Queries Queries yielding results for this class.
	Queries []QueryCount `json:"queries,omitempty" jsonschema:"Queries yielding results for this class."`

	// Result Serialized result contents, may be large.
	Result []Object `json:"result,omitempty" jsonschema:"Serialized result contents, may be large."`
}

Node Node in the result graph, contains results for a single class.

type Object

type Object = json.RawMessage

Object Data object serialized as JSON.

type ObjectsParams

type ObjectsParams struct {
	// Query Query string.
	Query Query `form:"query" json:"query"`
}

ObjectsParams defines parameters for Objects.

type ObjectsResponse

type ObjectsResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *[]map[string]interface{}
	JSON400      *Error
	JSON404      *Error
}

func ParseObjectsResponse

func ParseObjectsResponse(rsp *http.Response) (*ObjectsResponse, error)

ParseObjectsResponse parses an HTTP response from a ObjectsWithResponse call

func (ObjectsResponse) Status

func (r ObjectsResponse) Status() string

Status returns HTTPResponse.Status

func (ObjectsResponse) StatusCode

func (r ObjectsResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Query

type Query = string

Query Query for data objects, format is DOMAIN:CLASS:SELECTOR. DOMAIN: name of a domain (e.g. k8s, log, metric, alert, trace, netflow). CLASS: name of a class in the domain (e.g. Pod, application, metric, alert, span, network). SELECTOR: domain-specific query string.

type QueryCount

type QueryCount struct {
	// Count Number of results, omitted if the query was not executed.
	Count *int `json:"count,omitempty" jsonschema:"Number of results, omitted if the query was not executed."`

	// Query Query for correlation data.
	Query Query `json:"query" jsonschema:"Query for correlation data in DOMAIN:CLASS:SELECTOR format."`
}

QueryCount Query with number of results.

type RequestEditorFn

type RequestEditorFn func(ctx context.Context, req *http.Request) error

RequestEditorFn is the function signature for the RequestEditor callback function

type Rule

type Rule struct {
	// Name Name is an optional descriptive name.
	Name string `json:"name" jsonschema:"Name is an optional descriptive name."`

	// Queries Queries generated while following this rule.
	Queries []QueryCount `json:"queries,omitempty" jsonschema:"Queries generated while following this rule."`
}

Rule Rule is a correlation rule with a list of queries and results counts found during navigation.

type Search struct {
	// Goals Parameters for a goal-directed correlation search.
	Goals *Goals `json:"goals,omitempty" jsonschema:"Parameters for a goal-directed correlation search."`

	// Neighbors Parameters for a neighborhood correlation search.
	Neighbors *Neighbors `json:"neighbors,omitempty" jsonschema:"Parameters for a neighborhood correlation search."`
}

Search Correlation search parameters. Set exactly one of 'goals' (targeted search to specific classes) or 'neighbors' (open-ended exploration to a depth).

type SetConfigParams

type SetConfigParams struct {
	// Verbose Verbose level for logging.
	Verbose *int `form:"verbose,omitempty" json:"verbose,omitempty"`
}

SetConfigParams defines parameters for SetConfig.

type SetConfigResponse

type SetConfigResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *map[string]interface{}
}

func ParseSetConfigResponse

func ParseSetConfigResponse(rsp *http.Response) (*SetConfigResponse, error)

ParseSetConfigResponse parses an HTTP response from a SetConfigWithResponse call

func (SetConfigResponse) Status

func (r SetConfigResponse) Status() string

Status returns HTTPResponse.Status

func (SetConfigResponse) StatusCode

func (r SetConfigResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type SetConsoleJSONRequestBody

type SetConsoleJSONRequestBody = Console

SetConsoleJSONRequestBody defines body for SetConsole for application/json ContentType.

type SetConsoleResponse

type SetConsoleResponse struct {
	Body         []byte
	HTTPResponse *http.Response
	JSON200      *map[string]interface{}
	JSON400      *Error
}

func ParseSetConsoleResponse

func ParseSetConsoleResponse(rsp *http.Response) (*SetConsoleResponse, error)

ParseSetConsoleResponse parses an HTTP response from a SetConsoleWithResponse call

func (SetConsoleResponse) Status

func (r SetConsoleResponse) Status() string

Status returns HTTPResponse.Status

func (SetConsoleResponse) StatusCode

func (r SetConsoleResponse) StatusCode() int

StatusCode returns HTTPResponse.StatusCode

type Start

type Start struct {
	// Class Class of starting objects. Required when using 'objects' to provide serialized objects. If queries are included, they must all be of this class.
	Class Class `` /* 171-byte string literal not displayed */

	// Constraint Constrains the objects that will be included in search results.
	Constraint *Constraint `json:"constraint,omitempty" jsonschema:"Constrains the objects that will be included in search results."`

	// Objects Start objects serialized as JSON. Requires 'class' to identify the object type. Alternative to 'queries' when you already have the objects.
	Objects []Object `json:"objects,omitempty" jsonschema:"Start objects serialized as JSON. Requires class to identify the object type."`

	// Queries Queries for starting objects in "domain:class:selector" format. This is the most common way to specify a starting point.
	Queries []Query `json:"queries,omitempty" jsonschema:"Queries for starting objects in DOMAIN:CLASS:SELECTOR format."`
}

Start Starting point for a correlation search. It usually specifies queries to get the starting objects, but can include serialized objects as well as/instead of queries.

type Store

type Store map[string]string

Store Store is a map string keys and values used to connect to a store.

Jump to

Keyboard shortcuts

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