Documentation
¶
Index ¶
- Variables
- func CheckResponse(r *http.Response) error
- type APIKeyTransport
- type AddOpts
- type AlertsDeleteOpts
- type AlertsListOpts
- type AlertsService
- func (s *AlertsService) Add(ctx context.Context, alerts models.AddAlertsRequest) (*models.AddAlertsResponse, *Response, error)
- func (s *AlertsService) Delete(ctx context.Context, opts AlertsDeleteOpts) (*models.DeleteAlertsResponse, *Response, error)
- func (s *AlertsService) GetByID(ctx context.Context, alertID int) (*models.Alert, *Response, error)
- func (s *AlertsService) List(ctx context.Context, opts AlertsListOpts) (*models.GetAlertsResponse, *Response, error)
- type ApiClient
- type AuthService
- func (s *AuthService) AuthenticateWatcher(ctx context.Context, auth models.WatcherAuthRequest) (*Response, error)
- func (s *AuthService) RegisterWatcher(ctx context.Context, registration models.WatcherRegistrationRequest) (*Response, error)
- func (s *AuthService) UnregisterWatcher(ctx context.Context) (*Response, error)
- type Config
- type DecisionsDeleteOpts
- type DecisionsListOpts
- type DecisionsService
- func (s *DecisionsService) Delete(ctx context.Context, opts DecisionsDeleteOpts) (*models.DeleteDecisionResponse, *Response, error)
- func (s *DecisionsService) DeleteOne(ctx context.Context, decision_id string) (*models.DeleteDecisionResponse, *Response, error)
- func (s *DecisionsService) GetStream(ctx context.Context, startup bool) (*models.DecisionsStreamResponse, *Response, error)
- func (s *DecisionsService) List(ctx context.Context, opts DecisionsListOpts) (*models.GetDecisionsResponse, *Response, error)
- func (s *DecisionsService) StopStream(ctx context.Context) (*Response, error)
- type DeleteOpts
- type ErrorResponse
- type JWTTransport
- type ListOpts
- type MetricsService
- type Response
- type SignalService
Constants ¶
This section is empty.
Variables ¶
View Source
var (
InsecureSkipVerify = true
)
Functions ¶
func CheckResponse ¶
Types ¶
type APIKeyTransport ¶
type APIKeyTransport struct {
APIKey string
// Transport is the underlying HTTP transport to use when making requests.
// It will default to http.DefaultTransport if nil.
Transport http.RoundTripper
URL *url.URL
VersionPrefix string
UserAgent string
}
func (*APIKeyTransport) Client ¶
func (t *APIKeyTransport) Client() *http.Client
type AlertsDeleteOpts ¶
type AlertsDeleteOpts struct {
ScopeEquals *string `url:"scope,omitempty"`
ValueEquals *string `url:"value,omitempty"`
ScenarioEquals *string `url:"scenario,omitempty"`
IPEquals *string `url:"ip,omitempty"`
RangeEquals *string `url:"range,omitempty"`
Since *string `url:"since,omitempty"`
Until *string `url:"until,omitempty"`
ActiveDecisionEquals *bool `url:"has_active_decision,omitempty"`
SourceEquals *string `url:"alert_source,omitempty"`
ListOpts
}
type AlertsListOpts ¶
type AlertsListOpts struct {
ScopeEquals *string `url:"scope,omitempty"`
ValueEquals *string `url:"value,omitempty"`
ScenarioEquals *string `url:"scenario,omitempty"`
IPEquals *string `url:"ip,omitempty"`
RangeEquals *string `url:"range,omitempty"`
Since *string `url:"since,omitempty"`
TypeEquals *string `url:"decision_type,omitempty"`
Until *string `url:"until,omitempty"`
IncludeSimulated *bool `url:"simulated,omitempty"`
ActiveDecisionEquals *bool `url:"has_active_decision,omitempty"`
IncludeCAPI *bool `url:"include_capi,omitempty"`
Limit *int `url:"limit,omitempty"`
ListOpts
}
type AlertsService ¶
type AlertsService service
func (*AlertsService) Add ¶
func (s *AlertsService) Add(ctx context.Context, alerts models.AddAlertsRequest) (*models.AddAlertsResponse, *Response, error)
func (*AlertsService) Delete ¶
func (s *AlertsService) Delete(ctx context.Context, opts AlertsDeleteOpts) (*models.DeleteAlertsResponse, *Response, error)
to demo query arguments
func (*AlertsService) List ¶
func (s *AlertsService) List(ctx context.Context, opts AlertsListOpts) (*models.GetAlertsResponse, *Response, error)
to demo query arguments
type ApiClient ¶
type ApiClient struct {
/*config stuff*/
BaseURL *url.URL
URLPrefix string
UserAgent string
/*exposed Services*/
Decisions *DecisionsService
Alerts *AlertsService
Auth *AuthService
Metrics *MetricsService
Signal *SignalService
// contains filtered or unexported fields
}
func NewDefaultClient ¶
type AuthService ¶
type AuthService service
func (*AuthService) AuthenticateWatcher ¶
func (s *AuthService) AuthenticateWatcher(ctx context.Context, auth models.WatcherAuthRequest) (*Response, error)
func (*AuthService) RegisterWatcher ¶
func (s *AuthService) RegisterWatcher(ctx context.Context, registration models.WatcherRegistrationRequest) (*Response, error)
func (*AuthService) UnregisterWatcher ¶
func (s *AuthService) UnregisterWatcher(ctx context.Context) (*Response, error)
type DecisionsDeleteOpts ¶
type DecisionsListOpts ¶
type DecisionsService ¶
type DecisionsService service
func (*DecisionsService) Delete ¶
func (s *DecisionsService) Delete(ctx context.Context, opts DecisionsDeleteOpts) (*models.DeleteDecisionResponse, *Response, error)
func (*DecisionsService) DeleteOne ¶
func (s *DecisionsService) DeleteOne(ctx context.Context, decision_id string) (*models.DeleteDecisionResponse, *Response, error)
func (*DecisionsService) GetStream ¶
func (s *DecisionsService) GetStream(ctx context.Context, startup bool) (*models.DecisionsStreamResponse, *Response, error)
func (*DecisionsService) List ¶
func (s *DecisionsService) List(ctx context.Context, opts DecisionsListOpts) (*models.GetDecisionsResponse, *Response, error)
to demo query arguments
func (*DecisionsService) StopStream ¶
func (s *DecisionsService) StopStream(ctx context.Context) (*Response, error)
type DeleteOpts ¶
type DeleteOpts struct {
}
type ErrorResponse ¶
type ErrorResponse struct {
models.ErrorResponse
}
func (*ErrorResponse) Error ¶
func (e *ErrorResponse) Error() string
type JWTTransport ¶
type JWTTransport struct {
MachineID *string
Password *strfmt.Password
Expiration time.Time
Scenarios []string
URL *url.URL
VersionPrefix string
UserAgent string
// Transport is the underlying HTTP transport to use when making requests.
// It will default to http.DefaultTransport if nil.
Transport http.RoundTripper
UpdateScenario func() ([]string, error)
// contains filtered or unexported fields
}
func (*JWTTransport) Client ¶
func (t *JWTTransport) Client() *http.Client
type MetricsService ¶
type MetricsService service
type SignalService ¶
type SignalService service
func (*SignalService) Add ¶
func (s *SignalService) Add(ctx context.Context, signals *models.AddSignalsRequest) (interface{}, *Response, error)
Click to show internal directories.
Click to hide internal directories.