notifications

package
v2.16.0 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2023 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Overview

Code generated by tutone: DO NOT EDIT

Code generated by tutone: DO NOT EDIT

Index

Constants

View Source
const AiNotificationsCreateChannelMutation = `` /* 1305-byte string literal not displayed */
View Source
const AiNotificationsCreateDestinationMutation = `` /* 1654-byte string literal not displayed */
View Source
const AiNotificationsDeleteChannelMutation = `` /* 228-byte string literal not displayed */
View Source
const AiNotificationsDeleteDestinationMutation = `` /* 244-byte string literal not displayed */
View Source
const AiNotificationsUpdateChannelMutation = `` /* 1348-byte string literal not displayed */
View Source
const AiNotificationsUpdateDestinationMutation = `` /* 1709-byte string literal not displayed */

Variables

View Source
var AiNotificationsAuthTypeTypes = struct {
	// Basic user and password authentication
	BASIC AiNotificationsAuthType
	// OAuth based authentication
	OAUTH2 AiNotificationsAuthType
	// Token based authentication
	TOKEN AiNotificationsAuthType
}{

	BASIC: "BASIC",

	OAUTH2: "OAUTH2",

	TOKEN: "TOKEN",
}
View Source
var AiNotificationsChannelFieldsTypes = struct {
	// active field
	ACTIVE AiNotificationsChannelFields
	// created timestamp field
	CREATED_AT AiNotificationsChannelFields
	// default field
	DEFAULT AiNotificationsChannelFields
	// destination id field
	DESTINATION_ID AiNotificationsChannelFields
	// name field
	NAME AiNotificationsChannelFields
	// product field
	PRODUCT AiNotificationsChannelFields
	// status field
	STATUS AiNotificationsChannelFields
	// type field
	TYPE AiNotificationsChannelFields
	// updated timestamp field
	UPDATED_AT AiNotificationsChannelFields
	// updated_by field
	UPDATED_BY AiNotificationsChannelFields
}{

	ACTIVE: "ACTIVE",

	CREATED_AT: "CREATED_AT",

	DEFAULT: "DEFAULT",

	DESTINATION_ID: "DESTINATION_ID",

	NAME: "NAME",

	PRODUCT: "PRODUCT",

	STATUS: "STATUS",

	TYPE: "TYPE",

	UPDATED_AT: "UPDATED_AT",

	UPDATED_BY: "UPDATED_BY",
}
View Source
var AiNotificationsChannelStatusTypes = struct {
	// Configuration Error channel status
	CONFIGURATION_ERROR AiNotificationsChannelStatus
	// Configuration Warning channel status
	CONFIGURATION_WARNING AiNotificationsChannelStatus
	// Default channel status
	DEFAULT AiNotificationsChannelStatus
	// Draft channel status
	DRAFT AiNotificationsChannelStatus
	// Error channel status
	ERROR AiNotificationsChannelStatus
	// Tested channel status
	TESTED AiNotificationsChannelStatus
	// Throttled channel status
	THROTTLED AiNotificationsChannelStatus
	// Unknown Error channel status
	UNKNOWN_ERROR AiNotificationsChannelStatus
}{

	CONFIGURATION_ERROR: "CONFIGURATION_ERROR",

	CONFIGURATION_WARNING: "CONFIGURATION_WARNING",

	DEFAULT: "DEFAULT",

	DRAFT: "DRAFT",

	ERROR: "ERROR",

	TESTED: "TESTED",

	THROTTLED: "THROTTLED",

	UNKNOWN_ERROR: "UNKNOWN_ERROR",
}
View Source
var AiNotificationsChannelTypeTypes = struct {
	// Email channel type
	EMAIL AiNotificationsChannelType
	// Event Bridge channel type
	EVENT_BRIDGE AiNotificationsChannelType
	// Jira Classic channel type
	JIRA_CLASSIC AiNotificationsChannelType
	// Jira Nextgen channel type
	JIRA_NEXTGEN AiNotificationsChannelType
	// Mobile push channel type
	MOBILE_PUSH AiNotificationsChannelType
	// PagerDuty channel type
	PAGERDUTY_ACCOUNT_INTEGRATION AiNotificationsChannelType
	// Pager Duty channel type
	PAGERDUTY_SERVICE_INTEGRATION AiNotificationsChannelType
	// Servicenow events channel type
	SERVICENOW_EVENTS AiNotificationsChannelType
	// Servicenow incidents channel type
	SERVICENOW_INCIDENTS AiNotificationsChannelType
	// Slack channel type
	SLACK AiNotificationsChannelType
	// Slack Collaboration channel type
	SLACK_COLLABORATION AiNotificationsChannelType
	// Legacy Slack channel type based on Incoming Webhooks
	SLACK_LEGACY AiNotificationsChannelType
	// Webhook channel type
	WEBHOOK AiNotificationsChannelType
}{

	EMAIL: "EMAIL",

	EVENT_BRIDGE: "EVENT_BRIDGE",

	JIRA_CLASSIC: "JIRA_CLASSIC",

	JIRA_NEXTGEN: "JIRA_NEXTGEN",

	MOBILE_PUSH: "MOBILE_PUSH",

	PAGERDUTY_ACCOUNT_INTEGRATION: "PAGERDUTY_ACCOUNT_INTEGRATION",

	PAGERDUTY_SERVICE_INTEGRATION: "PAGERDUTY_SERVICE_INTEGRATION",

	SERVICENOW_EVENTS: "SERVICENOW_EVENTS",

	SERVICENOW_INCIDENTS: "SERVICENOW_INCIDENTS",

	SLACK: "SLACK",

	SLACK_COLLABORATION: "SLACK_COLLABORATION",

	SLACK_LEGACY: "SLACK_LEGACY",

	WEBHOOK: "WEBHOOK",
}
View Source
var AiNotificationsDestinationFieldsTypes = struct {
	// active field
	ACTIVE AiNotificationsDestinationFields
	// created_at field
	CREATED_AT AiNotificationsDestinationFields
	// default field
	DEFAULT AiNotificationsDestinationFields
	// last_sent field
	LAST_SENT AiNotificationsDestinationFields
	// name field
	NAME AiNotificationsDestinationFields
	// status field
	STATUS AiNotificationsDestinationFields
	// type field
	TYPE AiNotificationsDestinationFields
	// updated_at field
	UPDATED_AT AiNotificationsDestinationFields
	// updated_by field
	UPDATED_BY AiNotificationsDestinationFields
}{

	ACTIVE: "ACTIVE",

	CREATED_AT: "CREATED_AT",

	DEFAULT: "DEFAULT",

	LAST_SENT: "LAST_SENT",

	NAME: "NAME",

	STATUS: "STATUS",

	TYPE: "TYPE",

	UPDATED_AT: "UPDATED_AT",

	UPDATED_BY: "UPDATED_BY",
}
View Source
var AiNotificationsDestinationStatusTypes = struct {
	// Authentication Error destination status
	AUTHENTICATION_ERROR AiNotificationsDestinationStatus
	// Authorization Error destination status
	AUTHORIZATION_ERROR AiNotificationsDestinationStatus
	// Authorization Warning destination status
	AUTHORIZATION_WARNING AiNotificationsDestinationStatus
	// Configuration Error destination status
	CONFIGURATION_ERROR AiNotificationsDestinationStatus
	// Default destination status
	DEFAULT AiNotificationsDestinationStatus
	// Draft channel status
	DRAFT AiNotificationsDestinationStatus
	// Error channel status
	ERROR AiNotificationsDestinationStatus
	// Temporary Warning destination status
	TEMPORARY_WARNING AiNotificationsDestinationStatus
	// Tested channel status
	TESTED AiNotificationsDestinationStatus
	// Throttled channel status
	THROTTLED AiNotificationsDestinationStatus
	// Throttling Warning destination status
	THROTTLING_WARNING AiNotificationsDestinationStatus
	// Unknown Error destination status
	UNKNOWN_ERROR AiNotificationsDestinationStatus
}{

	AUTHENTICATION_ERROR: "AUTHENTICATION_ERROR",

	AUTHORIZATION_ERROR: "AUTHORIZATION_ERROR",

	AUTHORIZATION_WARNING: "AUTHORIZATION_WARNING",

	CONFIGURATION_ERROR: "CONFIGURATION_ERROR",

	DEFAULT: "DEFAULT",

	DRAFT: "DRAFT",

	ERROR: "ERROR",

	TEMPORARY_WARNING: "TEMPORARY_WARNING",

	TESTED: "TESTED",

	THROTTLED: "THROTTLED",

	THROTTLING_WARNING: "THROTTLING_WARNING",

	UNKNOWN_ERROR: "UNKNOWN_ERROR",
}
View Source
var AiNotificationsDestinationTypeTypes = struct {
	// Email destination type
	EMAIL AiNotificationsDestinationType
	// EventBridge destination type
	EVENT_BRIDGE AiNotificationsDestinationType
	// Jira destination type
	JIRA AiNotificationsDestinationType
	// Mobile push destination type
	MOBILE_PUSH AiNotificationsDestinationType
	// PagerDuty destination type
	PAGERDUTY_ACCOUNT_INTEGRATION AiNotificationsDestinationType
	// PagerDuty destination type}
	PAGERDUTY_SERVICE_INTEGRATION AiNotificationsDestinationType
	// ServiceNow destination type
	SERVICE_NOW AiNotificationsDestinationType
	// Slack destination type
	SLACK AiNotificationsDestinationType
	// Slack Collaboration destination type
	SLACK_COLLABORATION AiNotificationsDestinationType
	// Legacy Slack destination type based on Incoming Webhooks
	SLACK_LEGACY AiNotificationsDestinationType
	// WebHook destination type
	WEBHOOK AiNotificationsDestinationType
}{

	EMAIL: "EMAIL",

	EVENT_BRIDGE: "EVENT_BRIDGE",

	JIRA: "JIRA",

	MOBILE_PUSH: "MOBILE_PUSH",

	PAGERDUTY_ACCOUNT_INTEGRATION: "PAGERDUTY_ACCOUNT_INTEGRATION",

	PAGERDUTY_SERVICE_INTEGRATION: "PAGERDUTY_SERVICE_INTEGRATION",

	SERVICE_NOW: "SERVICE_NOW",

	SLACK: "SLACK",

	SLACK_COLLABORATION: "SLACK_COLLABORATION",

	SLACK_LEGACY: "SLACK_LEGACY",

	WEBHOOK: "WEBHOOK",
}
View Source
var AiNotificationsErrorTypeTypes = struct {
	// Unable to connect to external service to perform this action
	CONNECTION_ERROR AiNotificationsErrorType
	// This operation could not be completed because the entity is in use
	ENTITY_IN_USE AiNotificationsErrorType
	// The credentials provided were invalid, Please check them and try again
	INVALID_CREDENTIALS AiNotificationsErrorType
	// Could not provide suggestions for this key
	INVALID_KEY AiNotificationsErrorType
	// The parameter provided does not correspond to any valid entity
	INVALID_PARAMETER AiNotificationsErrorType
	// Entities limit has been reached
	LIMIT_REACHED AiNotificationsErrorType
	// User is missing capabilities
	MISSING_CAPABILITIES AiNotificationsErrorType
	// This key requires additional constraints
	MISSING_CONSTRAINTS AiNotificationsErrorType
	// At least one parameter is required to complete this action
	MISSING_PARAMETERS AiNotificationsErrorType
	// This destination does not support OAuth authentication
	OAUTH_NOT_SUPPORTED AiNotificationsErrorType
	// This destination does not provide any suggestions
	SUGGESTIONS_UNAVAILABLE AiNotificationsErrorType
	// Request did not finish within time limit
	TIMEOUT_ERROR AiNotificationsErrorType
	// The variable type is different from the example type
	TYPE_EXAMPLE_MISMATCH AiNotificationsErrorType
	// This account is not allowed to perform this action
	UNAUTHORIZED_ACCOUNT AiNotificationsErrorType
	// Received one or more unexpected parameters
	UNEXPECTED_PARAMETER AiNotificationsErrorType
	// An unknown error has occurred
	UNKNOWN_ERROR AiNotificationsErrorType
}{

	CONNECTION_ERROR: "CONNECTION_ERROR",

	ENTITY_IN_USE: "ENTITY_IN_USE",

	INVALID_CREDENTIALS: "INVALID_CREDENTIALS",

	INVALID_KEY: "INVALID_KEY",

	INVALID_PARAMETER: "INVALID_PARAMETER",

	LIMIT_REACHED: "LIMIT_REACHED",

	MISSING_CAPABILITIES: "MISSING_CAPABILITIES",

	MISSING_CONSTRAINTS: "MISSING_CONSTRAINTS",

	MISSING_PARAMETERS: "MISSING_PARAMETERS",

	OAUTH_NOT_SUPPORTED: "OAUTH_NOT_SUPPORTED",

	SUGGESTIONS_UNAVAILABLE: "SUGGESTIONS_UNAVAILABLE",

	TIMEOUT_ERROR: "TIMEOUT_ERROR",

	TYPE_EXAMPLE_MISMATCH: "TYPE_EXAMPLE_MISMATCH",

	UNAUTHORIZED_ACCOUNT: "UNAUTHORIZED_ACCOUNT",

	UNEXPECTED_PARAMETER: "UNEXPECTED_PARAMETER",

	UNKNOWN_ERROR: "UNKNOWN_ERROR",
}
View Source
var AiNotificationsProductTypes = struct {
	// Alerts product type
	ALERTS AiNotificationsProduct
	// Discussions and comments product type
	DISCUSSIONS AiNotificationsProduct
	// Error Tracking product type
	ERROR_TRACKING AiNotificationsProduct
	// Incident Intelligence product type
	IINT AiNotificationsProduct
	// Notifications internal product type
	NTFC AiNotificationsProduct
	// Proactive Detection product type
	PD AiNotificationsProduct
	// Sharing product type
	SHARING AiNotificationsProduct
}{

	ALERTS: "ALERTS",

	DISCUSSIONS: "DISCUSSIONS",

	ERROR_TRACKING: "ERROR_TRACKING",

	IINT: "IINT",

	NTFC: "NTFC",

	PD: "PD",

	SHARING: "SHARING",
}
View Source
var AiNotificationsSortOrderTypes = struct {
	// Ascending sort order
	ASC AiNotificationsSortOrder
	// Descending sort order
	DESC AiNotificationsSortOrder
}{

	ASC: "ASC",

	DESC: "DESC",
}
View Source
var AlertsNotificationChannelTypeTypes = struct {
	// Campfire notification channel.
	CAMPFIRE AlertsNotificationChannelType
	// Email notification channel.
	EMAIL AlertsNotificationChannelType
	// HipChat notification channel.
	HIP_CHAT AlertsNotificationChannelType
	// OpsGenie notification channel.
	OPSGENIE AlertsNotificationChannelType
	// PagerDuty notification channel.
	PAGERDUTY AlertsNotificationChannelType
	// Slack notification channel.
	SLACK AlertsNotificationChannelType
	// User notification channel.
	USER AlertsNotificationChannelType
	// VictorOps notification channel.
	VICTOROPS AlertsNotificationChannelType
	// Webhook notification channel.
	WEBHOOK AlertsNotificationChannelType
	// xMatters notification channel.
	XMATTERS AlertsNotificationChannelType
}{

	CAMPFIRE: "CAMPFIRE",

	EMAIL: "EMAIL",

	HIP_CHAT: "HIP_CHAT",

	OPSGENIE: "OPSGENIE",

	PAGERDUTY: "PAGERDUTY",

	SLACK: "SLACK",

	USER: "USER",

	VICTOROPS: "VICTOROPS",

	WEBHOOK: "WEBHOOK",

	XMATTERS: "XMATTERS",
}
View Source
var AlertsOpsGenieDataCenterRegionTypes = struct {
	// EU data center region
	EU AlertsOpsGenieDataCenterRegion
	// US data center region
	US AlertsOpsGenieDataCenterRegion
}{

	EU: "EU",

	US: "US",
}
View Source
var AlertsWebhookCustomPayloadTypeTypes = struct {
	// FORM payload type
	FORM AlertsWebhookCustomPayloadType
	// JSON payload type
	JSON AlertsWebhookCustomPayloadType
}{

	FORM: "FORM",

	JSON: "JSON",
}

Functions

This section is empty.

Types

type Account

type Account struct {
	// This field provides access to AiNotifications data.
	AiNotifications AiNotificationsAccountStitchedFields `json:"aiNotifications,omitempty"`
	//
	ID int `json:"id,omitempty"`
	//
	LicenseKey string `json:"licenseKey,omitempty"`
	//
	Name string `json:"name,omitempty"`
}

Account - The `Account` object provides general data about the account, as well as being the entry point into more detailed data about a single account.

Account configuration data is queried through this object, as well as telemetry data that is specific to a single account.

type Actor

type Actor struct {
	// The `account` field is the entry point into data that is scoped to a single account.
	Account Account `json:"account,omitempty"`
}

Actor - The `Actor` object contains fields that are scoped to the API user's access level.

type AiNotificationsAccountStitchedFields

type AiNotificationsAccountStitchedFields struct {
	// Fetch a Channel by product
	Channels AiNotificationsChannelsResponse `json:"channels,omitempty"`
	// Fetch a Destinations by type
	Destinations AiNotificationsDestinationsResponse `json:"destinations,omitempty"`
}

AiNotificationsAccountStitchedFields -

type AiNotificationsAuthType

type AiNotificationsAuthType string

AiNotificationsAuthType - Authentication types

type AiNotificationsBasicAuthInput

type AiNotificationsBasicAuthInput struct {
	// password
	Password SecureValue `json:"password"`
	// user
	User string `json:"user"`
}

AiNotificationsBasicAuthInput - Basic auth input object

type AiNotificationsChannel

type AiNotificationsChannel struct {
	// The accountId of the creator of the channel
	AccountID int `json:"accountId"`
	// Is channel active
	Active bool `json:"active"`
	// Channel creation time
	CreatedAt nrtime.DateTime `json:"createdAt"`
	// Related destination type
	DestinationId string `json:"destinationId"`
	// Channel id
	ID string `json:"id"`
	// Channel name
	Name string `json:"name"`
	// Related product type
	Product AiNotificationsProduct `json:"product"`
	// List of destination property types
	Properties []AiNotificationsProperty `json:"properties"`
	// Channel Status
	Status AiNotificationsChannelStatus `json:"status"`
	// Channel type
	Type AiNotificationsChannelType `json:"type"`
	// Channel last update time
	UpdatedAt nrtime.DateTime `json:"updatedAt"`
	// Message template creator userId
	UpdatedBy int `json:"updatedBy"`
}

AiNotificationsChannel - Channel object

type AiNotificationsChannelFields

type AiNotificationsChannelFields string

AiNotificationsChannelFields - Channel fields to filter by

type AiNotificationsChannelFilter

type AiNotificationsChannelFilter struct {
	// active
	Active bool `json:"active,omitempty"`
	// destinationId
	DestinationId string `json:"destinationId,omitempty"`
	// id
	ID string `json:"id,omitempty"`
	// name
	Name string `json:"name,omitempty"`
	// product
	Product AiNotificationsProduct `json:"product,omitempty"`
	// property
	Property AiNotificationsPropertyFilter `json:"property,omitempty"`
	// type
	Type AiNotificationsChannelType `json:"type,omitempty"`
}

AiNotificationsChannelFilter - Filter channel object

type AiNotificationsChannelInput

type AiNotificationsChannelInput struct {
	// destinationId
	DestinationId string `json:"destinationId"`
	// name
	Name string `json:"name"`
	// product
	Product AiNotificationsProduct `json:"product"`
	// properties
	Properties []AiNotificationsPropertyInput `json:"properties,omitempty"`
	// type
	Type AiNotificationsChannelType `json:"type"`
}

AiNotificationsChannelInput - Channel input object

type AiNotificationsChannelResponse

type AiNotificationsChannelResponse struct {
	// Successfully mutated channel
	Channel AiNotificationsChannel `json:"channel,omitempty"`
	// Error in channel mutation
	Error ai.AiNotificationsError `json:"error,omitempty"`
	// Deprecated list of errors
	Errors []ai.AiNotificationsError `json:"errors"`
}

AiNotificationsChannelResponse - Response for all channel related mutations. Includes relevant channel and/or errors

type AiNotificationsChannelSorter

type AiNotificationsChannelSorter struct {
	// direction
	Direction AiNotificationsSortOrder `json:"direction"`
	// field
	Field AiNotificationsChannelFields `json:"field"`
}

AiNotificationsChannelSorter - Sort object

type AiNotificationsChannelStatus

type AiNotificationsChannelStatus string

AiNotificationsChannelStatus - Channel statuses

type AiNotificationsChannelType

type AiNotificationsChannelType string

AiNotificationsChannelType - Channel type

type AiNotificationsChannelUpdate

type AiNotificationsChannelUpdate struct {
	// active
	Active bool `json:"active,omitempty"`
	// name
	Name string `json:"name,omitempty"`
	// properties
	Properties []AiNotificationsPropertyInput `json:"properties,omitempty"`
}

AiNotificationsChannelUpdate - Channel update object

type AiNotificationsChannelsResponse

type AiNotificationsChannelsResponse struct {
	// Channel entities
	Entities []AiNotificationsChannel `json:"entities"`
	// Error in channel entities fetching
	Error AiNotificationsResponseError `json:"error,omitempty"`
	// Deprecated list of errors
	Errors []AiNotificationsResponseError `json:"errors"`
	// Cursor to get the next batch of results
	NextCursor string `json:"nextCursor,omitempty"`
	// Count of all channel entities
	TotalCount int `json:"totalCount"`
}

AiNotificationsChannelsResponse - Channel result object

type AiNotificationsCreateChannelQueryResponse

type AiNotificationsCreateChannelQueryResponse struct {
	AiNotificationsChannelResponse AiNotificationsChannelResponse `json:"AiNotificationsCreateChannel"`
}

type AiNotificationsCreateDestinationQueryResponse

type AiNotificationsCreateDestinationQueryResponse struct {
	AiNotificationsDestinationResponse AiNotificationsDestinationResponse `json:"AiNotificationsCreateDestination"`
}

type AiNotificationsCredentialsInput

type AiNotificationsCredentialsInput struct {
	// basic
	Basic AiNotificationsBasicAuthInput `json:"basic,omitempty"`
	// oauth2
	Oauth2 AiNotificationsOAuth2AuthInput `json:"oauth2,omitempty"`
	// token
	Token AiNotificationsTokenAuthInput `json:"token,omitempty"`
	// type
	Type AiNotificationsAuthType `json:"type"`
}

AiNotificationsCredentialsInput - Credential input object

type AiNotificationsDeleteChannelQueryResponse

type AiNotificationsDeleteChannelQueryResponse struct {
	AiNotificationsDeleteResponse AiNotificationsDeleteResponse `json:"AiNotificationsDeleteChannel"`
}

type AiNotificationsDeleteDestinationQueryResponse

type AiNotificationsDeleteDestinationQueryResponse struct {
	AiNotificationsDeleteResponse AiNotificationsDeleteResponse `json:"AiNotificationsDeleteDestination"`
}

type AiNotificationsDeleteResponse

type AiNotificationsDeleteResponse struct {
	// Error in object deletion
	Error AiNotificationsResponseError `json:"error,omitempty"`
	// Deprecated list of errors
	Errors []AiNotificationsResponseError `json:"errors"`
	// Deleted object ids
	IDs []string `json:"ids"`
}

AiNotificationsDeleteResponse - Delete response object

type AiNotificationsDestination

type AiNotificationsDestination struct {
	// The accountId of the creator of the destination
	AccountID int `json:"accountId"`
	// Destination active
	Active bool `json:"active"`
	// Authentication for this destination
	Auth ai.AiNotificationsAuth `json:"auth,omitempty"`
	// Destination created at
	CreatedAt nrtime.DateTime `json:"createdAt"`
	// Destination id
	ID string `json:"id"`
	// Indicates whether the user is authenticated with the destination
	IsUserAuthenticated bool `json:"isUserAuthenticated"`
	// Last time a notification was sent
	LastSent nrtime.DateTime `json:"lastSent,omitempty"`
	// Destination name
	Name string `json:"name"`
	// List of destination property types
	Properties []AiNotificationsProperty `json:"properties"`
	// Destination status
	Status AiNotificationsDestinationStatus `json:"status"`
	// Destination type
	Type AiNotificationsDestinationType `json:"type"`
	// Destination updated at
	UpdatedAt nrtime.DateTime `json:"updatedAt"`
	// Destination updated by
	UpdatedBy int `json:"updatedBy"`
}

AiNotificationsDestination - Destination Object

type AiNotificationsDestinationFields

type AiNotificationsDestinationFields string

AiNotificationsDestinationFields - Destination fields

type AiNotificationsDestinationFilter

type AiNotificationsDestinationFilter struct {
	// active
	Active bool `json:"active,omitempty"`
	// authType
	AuthType AiNotificationsAuthType `json:"authType,omitempty"`
	// id
	ID string `json:"id,omitempty"`
	// name
	Name string `json:"name,omitempty"`
	// property
	Property AiNotificationsPropertyFilter `json:"property,omitempty"`
	// type
	Type AiNotificationsDestinationType `json:"type,omitempty"`
	// updatedAt
	UpdatedAt nrtime.DateTime `json:"updatedAt,omitempty"`
}

AiNotificationsDestinationFilter - Filter destination object

type AiNotificationsDestinationInput

type AiNotificationsDestinationInput struct {
	// auth
	Auth *AiNotificationsCredentialsInput `json:"auth,omitempty"`
	// name
	Name string `json:"name"`
	// properties
	Properties []AiNotificationsPropertyInput `json:"properties,omitempty"`
	// type
	Type AiNotificationsDestinationType `json:"type"`
}

AiNotificationsDestinationInput - Destination input object

type AiNotificationsDestinationResponse

type AiNotificationsDestinationResponse struct {
	// Successfully mutated destination
	Destination AiNotificationsDestination `json:"destination,omitempty"`
	// Error in destination mutation
	Error ai.AiNotificationsError `json:"error,omitempty"`
	// Deprecated list of errors
	Errors []ai.AiNotificationsError `json:"errors"`
}

AiNotificationsDestinationResponse - Response for all destinations related mutation. Includes relevant destination and/or errors

type AiNotificationsDestinationSorter

type AiNotificationsDestinationSorter struct {
	// direction
	Direction AiNotificationsSortOrder `json:"direction"`
	// field
	Field AiNotificationsDestinationFields `json:"field"`
}

AiNotificationsDestinationSorter - Sort object

type AiNotificationsDestinationStatus

type AiNotificationsDestinationStatus string

AiNotificationsDestinationStatus - Destination statuses

type AiNotificationsDestinationType

type AiNotificationsDestinationType string

AiNotificationsDestinationType - Destination types

type AiNotificationsDestinationUpdate

type AiNotificationsDestinationUpdate struct {
	// active
	Active bool `json:"active,omitempty"`
	// auth
	Auth *AiNotificationsCredentialsInput `json:"auth,omitempty"`
	// disableAuth
	DisableAuth bool `json:"disableAuth,omitempty"`
	// name
	Name string `json:"name,omitempty"`
	// properties
	Properties []AiNotificationsPropertyInput `json:"properties,omitempty"`
}

AiNotificationsDestinationUpdate - Destination update object

type AiNotificationsDestinationsResponse

type AiNotificationsDestinationsResponse struct {
	// Destination entities
	Entities []AiNotificationsDestination `json:"entities"`
	// Error in destinations entities fetching
	Error AiNotificationsResponseError `json:"error,omitempty"`
	// Deprecated list of errors
	Errors []AiNotificationsResponseError `json:"errors"`
	// Cursor to get the next batch of results
	NextCursor string `json:"nextCursor,omitempty"`
	// Count of all destination entities
	TotalCount int `json:"totalCount"`
}

AiNotificationsDestinationsResponse - Destinations result object

type AiNotificationsErrorType

type AiNotificationsErrorType string

AiNotificationsErrorType - Error types

type AiNotificationsOAuth2AuthInput

type AiNotificationsOAuth2AuthInput struct {
	// accessTokenUrl
	AccessTokenURL string `json:"accessTokenUrl"`
	// authorizationUrl
	AuthorizationURL string `json:"authorizationUrl"`
	// clientId
	ClientId string `json:"clientId"`
	// clientSecret
	ClientSecret SecureValue `json:"clientSecret"`
	// prefix
	Prefix string `json:"prefix,omitempty"`
	// refreshInterval
	RefreshInterval int `json:"refreshInterval,omitempty"`
	// refreshToken
	RefreshToken SecureValue `json:"refreshToken,omitempty"`
	// refreshable
	Refreshable bool `json:"refreshable"`
	// scope
	Scope string `json:"scope,omitempty"`
	// token
	Token SecureValue `json:"token"`
}

AiNotificationsOAuth2AuthInput - OAuth2 auth input object

type AiNotificationsProduct

type AiNotificationsProduct string

AiNotificationsProduct - Product types

type AiNotificationsProperty

type AiNotificationsProperty struct {
	// Channel property display key
	DisplayValue string `json:"displayValue,omitempty"`
	// Channel property key
	Key string `json:"key"`
	// Channel property display key
	Label string `json:"label,omitempty"`
	// Channel property value
	Value string `json:"value"`
}

AiNotificationsProperty - Channel property Object

type AiNotificationsPropertyFilter

type AiNotificationsPropertyFilter struct {
	// key
	Key string `json:"key"`
	// value
	Value string `json:"value"`
}

AiNotificationsPropertyFilter - Filter object by property

type AiNotificationsPropertyInput

type AiNotificationsPropertyInput struct {
	// displayValue
	DisplayValue string `json:"displayValue,omitempty"`
	// key
	Key string `json:"key"`
	// label
	Label string `json:"label,omitempty"`
	// value
	Value string `json:"value"`
}

AiNotificationsPropertyInput - Property object

type AiNotificationsResponseError

type AiNotificationsResponseError struct {
	// Error description
	Description string `json:"description"`
	// Error details
	Details string `json:"details"`
	// Error type
	Type AiNotificationsErrorType `json:"type"`
}

AiNotificationsResponseError - Response error object

type AiNotificationsSortOrder

type AiNotificationsSortOrder string

AiNotificationsSortOrder - Sort order

type AiNotificationsTokenAuthInput

type AiNotificationsTokenAuthInput struct {
	// prefix
	Prefix string `json:"prefix,omitempty"`
	// token
	Token SecureValue `json:"token"`
}

AiNotificationsTokenAuthInput - Token auth input object

type AiNotificationsUpdateChannelQueryResponse

type AiNotificationsUpdateChannelQueryResponse struct {
	AiNotificationsChannelResponse AiNotificationsChannelResponse `json:"AiNotificationsUpdateChannel"`
}

type AiNotificationsUpdateDestinationQueryResponse

type AiNotificationsUpdateDestinationQueryResponse struct {
	AiNotificationsDestinationResponse AiNotificationsDestinationResponse `json:"AiNotificationsUpdateDestination"`
}

type AlertsCampfireNotificationChannel

type AlertsCampfireNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// Campfire channel specific configuration.
	Config AlertsCampfireNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsCampfireNotificationChannel - Campfire notification channel.

func (*AlertsCampfireNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsCampfireNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsCampfireNotificationChannelConfig

type AlertsCampfireNotificationChannelConfig struct {
	// Room.
	Room string `json:"room"`
	// Subdomain.
	Subdomain string `json:"subdomain"`
	// Authentication token.
	Token SecureValue `json:"token"`
}

AlertsCampfireNotificationChannelConfig - Configuration for Campfire notification channel.

type AlertsEmailNotificationChannel

type AlertsEmailNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// Email channel specific configuration.
	Config AlertsEmailNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsEmailNotificationChannel - Email notification channel.

func (*AlertsEmailNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsEmailNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsEmailNotificationChannelConfig

type AlertsEmailNotificationChannelConfig struct {
	// List of email recipients.
	Emails []string `json:"emails"`
	// Include details about the violation as a JSON attachment.
	IncludeJson bool `json:"includeJson"`
}

AlertsEmailNotificationChannelConfig - Configuration for Email notification channel.

type AlertsHipChatNotificationChannel

type AlertsHipChatNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// HipChat channel specific configuration.
	Config AlertsHipChatNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsHipChatNotificationChannel - HipChat notification channel.

func (*AlertsHipChatNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsHipChatNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsHipChatNotificationChannelConfig

type AlertsHipChatNotificationChannelConfig struct {
	// Authentication token.
	AuthToken SecureValue `json:"authToken"`
	// Base URL.
	BaseURL string `json:"baseUrl"`
	// Room ID.
	RoomId string `json:"roomId"`
}

AlertsHipChatNotificationChannelConfig - Configuration for HipChat notification channel.

type AlertsNotificationChannel

type AlertsNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsNotificationChannel - A notification channel.

func (*AlertsNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsNotificationChannelInterface

type AlertsNotificationChannelInterface interface {
	ImplementsAlertsNotificationChannel()
}

AlertsNotificationChannel - A notification channel.

func UnmarshalAlertsNotificationChannelInterface

func UnmarshalAlertsNotificationChannelInterface(b []byte) (*AlertsNotificationChannelInterface, error)

UnmarshalAlertsNotificationChannelInterface unmarshals the interface into the correct type based on __typename provided by GraphQL

type AlertsNotificationChannelPoliciesResultSet

type AlertsNotificationChannelPoliciesResultSet struct {
	// A set of policies associated with the channel.
	Policies []AlertsNotificationChannelPolicy `json:"policies"`
	// Total number of policies associated with the channel.
	TotalCount int `json:"totalCount"`
}

AlertsNotificationChannelPoliciesResultSet - A result set containing associated policies information for a notification channel.

type AlertsNotificationChannelPolicy

type AlertsNotificationChannelPolicy struct {
	// Policy ID.
	ID string `json:"id"`
	// Policy name.
	Name string `json:"name"`
}

AlertsNotificationChannelPolicy - Information about a policy associated with a notification channel.

type AlertsNotificationChannelType

type AlertsNotificationChannelType string

AlertsNotificationChannelType - The type of the notification channel which determines its configuration field.

type AlertsOpsGenieDataCenterRegion

type AlertsOpsGenieDataCenterRegion string

AlertsOpsGenieDataCenterRegion - OpsGenie data center region

type AlertsOpsGenieNotificationChannel

type AlertsOpsGenieNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// OpsGenie channel specific configuration.
	Config AlertsOpsGenieNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsOpsGenieNotificationChannel - OpsGenie notification channel.

func (*AlertsOpsGenieNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsOpsGenieNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsOpsGenieNotificationChannelConfig

type AlertsOpsGenieNotificationChannelConfig struct {
	// API key.
	APIKey SecureValue `json:"apiKey"`
	// OpsGenie data center region.
	DataCenterRegion AlertsOpsGenieDataCenterRegion `json:"dataCenterRegion"`
	// List of email recipients.
	Recipients []string `json:"recipients"`
	// Tags.
	Tags []string `json:"tags"`
	// Teams.
	Teams []string `json:"teams"`
}

AlertsOpsGenieNotificationChannelConfig - Configuration for OpsGenie notification channel.

type AlertsPagerDutyNotificationChannel

type AlertsPagerDutyNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// PagerDuty channel specific configuration.
	Config AlertsPagerDutyNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsPagerDutyNotificationChannel - PagerDuty notification channel.

func (*AlertsPagerDutyNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsPagerDutyNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsPagerDutyNotificationChannelConfig

type AlertsPagerDutyNotificationChannelConfig struct {
	// API key.
	APIKey SecureValue `json:"apiKey"`
}

AlertsPagerDutyNotificationChannelConfig - Configuration for PagerDuty notification channel.

type AlertsSlackNotificationChannel

type AlertsSlackNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// Slack channel specific configuration.
	Config AlertsSlackNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsSlackNotificationChannel - Slack notification channel.

func (*AlertsSlackNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsSlackNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsSlackNotificationChannelConfig

type AlertsSlackNotificationChannelConfig struct {
	// Slack channel name.
	TeamChannel string `json:"teamChannel,omitempty"`
	// Slack channel URL.
	URL SecureValue `json:"url"`
}

AlertsSlackNotificationChannelConfig - Configuration for Slack notification channel.

type AlertsUserNotificationChannel

type AlertsUserNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// User channel specific configuration.
	Config AlertsUserNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsUserNotificationChannel - User notification channel.

func (*AlertsUserNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsUserNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsUserNotificationChannelConfig

type AlertsUserNotificationChannelConfig struct {
	// User ID.
	UserID string `json:"userId"`
}

AlertsUserNotificationChannelConfig - Configuration for user notification channel.

type AlertsVictorOpsNotificationChannel

type AlertsVictorOpsNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// VictorOps channel specific configuration.
	Config AlertsVictorOpsNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsVictorOpsNotificationChannel - VictorOps notification channel.

func (*AlertsVictorOpsNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsVictorOpsNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsVictorOpsNotificationChannelConfig

type AlertsVictorOpsNotificationChannelConfig struct {
	// Key.
	Key SecureValue `json:"key"`
	// Route key.
	RouteKey string `json:"routeKey"`
}

AlertsVictorOpsNotificationChannelConfig - Configuration for VictorOps notification channel.

type AlertsWebhookBasicAuthInput

type AlertsWebhookBasicAuthInput struct {
	// Password
	Password SecureValue `json:"password"`
	// Username
	Username string `json:"username"`
}

AlertsWebhookBasicAuthInput - Webhook basic auth

type AlertsWebhookCustomHeaderInput

type AlertsWebhookCustomHeaderInput struct {
	// Header name
	Name string `json:"name"`
	// Header value
	Value SecureValue `json:"value"`
}

AlertsWebhookCustomHeaderInput - Webhook header

type AlertsWebhookCustomPayloadType

type AlertsWebhookCustomPayloadType string

AlertsWebhookCustomPayloadType - Webhook custom payload type

type AlertsWebhookNotificationChannel

type AlertsWebhookNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// Webhook channel specific configuration.
	Config AlertsWebhookNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsWebhookNotificationChannel - Webhook notification channel.

func (*AlertsWebhookNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsWebhookNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsWebhookNotificationChannelConfig

type AlertsWebhookNotificationChannelConfig struct {
	// Base URL.
	BaseURL string `json:"baseUrl"`
	// Basic auth.
	BasicAuth AlertsWebhookBasicAuthInput `json:"basicAuth,omitempty"`
	// Custom HTTP headers.
	CustomHttpHeaders []AlertsWebhookCustomHeaderInput `json:"customHttpHeaders"`
	// Custom payload body.
	CustomPayloadBody string `json:"customPayloadBody,omitempty"`
	// Custom payload type.
	CustomPayloadType AlertsWebhookCustomPayloadType `json:"customPayloadType,omitempty"`
}

AlertsWebhookNotificationChannelConfig - Configuration for Webhook notification channel.

type AlertsXMattersNotificationChannel

type AlertsXMattersNotificationChannel struct {
	// Policies associated with the channel.
	AssociatedPolicies AlertsNotificationChannelPoliciesResultSet `json:"associatedPolicies"`
	// xMatters channel specific configuration.
	Config AlertsXMattersNotificationChannelConfig `json:"config"`
	// Channel ID.
	ID string `json:"id"`
	// Channel name.
	Name string `json:"name"`
	// Channel type.
	Type AlertsNotificationChannelType `json:"type"`
}

AlertsXMattersNotificationChannel - xMatters notification channel.

func (*AlertsXMattersNotificationChannel) ImplementsAlertsNotificationChannel

func (x *AlertsXMattersNotificationChannel) ImplementsAlertsNotificationChannel()

type AlertsXMattersNotificationChannelConfig

type AlertsXMattersNotificationChannelConfig struct {
	// Integration URL.
	IntegrationURL SecureValue `json:"integrationUrl"`
}

AlertsXMattersNotificationChannelConfig - Configuration for xMatters notification channel.

type Notifications

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

Notifications are used to communicate with New Relic Notifications.

func New

func New(config config.Config) Notifications

New is used to create a new Notifications' client instance.

func (*Notifications) AiNotificationsCreateChannel

func (a *Notifications) AiNotificationsCreateChannel(
	accountID int,
	channel AiNotificationsChannelInput,
) (*AiNotificationsChannelResponse, error)

Create a Channel

func (*Notifications) AiNotificationsCreateChannelWithContext

func (a *Notifications) AiNotificationsCreateChannelWithContext(
	ctx context.Context,
	accountID int,
	channel AiNotificationsChannelInput,
) (*AiNotificationsChannelResponse, error)

Create a Channel

func (*Notifications) AiNotificationsCreateDestination

func (a *Notifications) AiNotificationsCreateDestination(
	accountID int,
	destination AiNotificationsDestinationInput,
) (*AiNotificationsDestinationResponse, error)

Create a Destination

func (*Notifications) AiNotificationsCreateDestinationWithContext

func (a *Notifications) AiNotificationsCreateDestinationWithContext(
	ctx context.Context,
	accountID int,
	destination AiNotificationsDestinationInput,
) (*AiNotificationsDestinationResponse, error)

Create a Destination

func (*Notifications) AiNotificationsDeleteChannel

func (a *Notifications) AiNotificationsDeleteChannel(
	accountID int,
	channelId string,
) (*AiNotificationsDeleteResponse, error)

Delete a Channel

func (*Notifications) AiNotificationsDeleteChannelWithContext

func (a *Notifications) AiNotificationsDeleteChannelWithContext(
	ctx context.Context,
	accountID int,
	channelId string,
) (*AiNotificationsDeleteResponse, error)

Delete a Channel

func (*Notifications) AiNotificationsDeleteDestination

func (a *Notifications) AiNotificationsDeleteDestination(
	accountID int,
	destinationId string,
) (*AiNotificationsDeleteResponse, error)

Delete a Destination

func (*Notifications) AiNotificationsDeleteDestinationWithContext

func (a *Notifications) AiNotificationsDeleteDestinationWithContext(
	ctx context.Context,
	accountID int,
	destinationId string,
) (*AiNotificationsDeleteResponse, error)

Delete a Destination

func (*Notifications) AiNotificationsUpdateChannel

func (a *Notifications) AiNotificationsUpdateChannel(
	accountID int,
	channel AiNotificationsChannelUpdate,
	channelId string,
) (*AiNotificationsChannelResponse, error)

Update a Channel

func (*Notifications) AiNotificationsUpdateChannelWithContext

func (a *Notifications) AiNotificationsUpdateChannelWithContext(
	ctx context.Context,
	accountID int,
	channel AiNotificationsChannelUpdate,
	channelId string,
) (*AiNotificationsChannelResponse, error)

Update a Channel

func (*Notifications) AiNotificationsUpdateDestination

func (a *Notifications) AiNotificationsUpdateDestination(
	accountID int,
	destination AiNotificationsDestinationUpdate,
	destinationId string,
) (*AiNotificationsDestinationResponse, error)

Update a Destination

func (*Notifications) AiNotificationsUpdateDestinationWithContext

func (a *Notifications) AiNotificationsUpdateDestinationWithContext(
	ctx context.Context,
	accountID int,
	destination AiNotificationsDestinationUpdate,
	destinationId string,
) (*AiNotificationsDestinationResponse, error)

Update a Destination

func (*Notifications) GetChannels

Fetch a Channel by product

func (*Notifications) GetChannelsWithContext

func (a *Notifications) GetChannelsWithContext(
	ctx context.Context,
	accountID int,
	cursor string,
	filters ai.AiNotificationsChannelFilter,
	sorter AiNotificationsChannelSorter,
) (*AiNotificationsChannelsResponse, error)

Fetch a Channel by product

func (*Notifications) GetDestinations

Fetch a Destinations by type

func (*Notifications) GetDestinationsWithContext

func (a *Notifications) GetDestinationsWithContext(
	ctx context.Context,
	accountID int,
	cursor string,
	filters ai.AiNotificationsDestinationFilter,
	sorter AiNotificationsDestinationSorter,
) (*AiNotificationsDestinationsResponse, error)

Fetch a Destinations by type

type SecureValue

type SecureValue string

SecureValue - The `SecureValue` scalar represents a secure value, ie a password, an API key, etc.

Jump to

Keyboard shortcuts

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