Documentation ¶
Index ¶
- Variables
- func ApplyConfigValues(cfg config.Config, vals []ConfigValueInput) (config.Config, error)
- func MarshalClockTime(c rule.Clock) graphql.Marshaler
- func MarshalContactMethodType(t contactmethod.Type) graphql.Marshaler
- func MarshalISOTimestamp(t time.Time) graphql.Marshaler
- func NewExecutableSchema(cfg Config) graphql.ExecutableSchema
- func UnmarshalClockTime(v interface{}) (rule.Clock, error)
- func UnmarshalContactMethodType(v interface{}) (contactmethod.Type, error)
- func UnmarshalISOTimestamp(v interface{}) (time.Time, error)
- type AlertConnection
- type AlertLogEntryConnection
- type AlertLogEntryResolver
- type AlertRecentEventsOptions
- type AlertResolver
- type AlertSearchOptions
- type AlertStatus
- type AuthSubjectConnection
- type ComplexityRoot
- type Config
- type ConfigType
- type ConfigValue
- type ConfigValueInput
- type CreateAlertInput
- type CreateEscalationPolicyInput
- type CreateEscalationPolicyStepInput
- type CreateHeartbeatMonitorInput
- type CreateIntegrationKeyInput
- type CreateRotationInput
- type CreateScheduleInput
- type CreateServiceInput
- type CreateUserContactMethodInput
- type CreateUserNotificationRuleInput
- type CreateUserOverrideInput
- type DirectiveRoot
- type EscalationPolicyConnection
- type EscalationPolicyResolver
- type EscalationPolicySearchOptions
- type EscalationPolicyStepResolver
- type HeartbeatMonitorResolver
- type IntegrationKeyResolver
- type IntegrationKeyType
- type LabelConnection
- type LabelSearchOptions
- type MutationResolver
- type OnCallShiftResolver
- type PageInfo
- type QueryResolver
- type ResolverRoot
- type RotationConnection
- type RotationResolver
- type RotationSearchOptions
- type ScheduleConnection
- type ScheduleResolver
- type ScheduleRuleInput
- type ScheduleRuleResolver
- type ScheduleSearchOptions
- type ScheduleTarget
- type ScheduleTargetInput
- type SendContactMethodVerificationInput
- type ServiceConnection
- type ServiceResolver
- type ServiceSearchOptions
- type SetFavoriteInput
- type SetLabelInput
- type SlackChannelConnection
- type SlackChannelSearchOptions
- type TargetResolver
- type TimeZone
- type TimeZoneConnection
- type TimeZoneSearchOptions
- type UpdateAlertsInput
- type UpdateEscalationPolicyInput
- type UpdateEscalationPolicyStepInput
- type UpdateHeartbeatMonitorInput
- type UpdateRotationInput
- type UpdateScheduleInput
- type UpdateServiceInput
- type UpdateUserContactMethodInput
- type UpdateUserInput
- type UpdateUserOverrideInput
- type UserConnection
- type UserContactMethodResolver
- type UserNotificationRuleResolver
- type UserOverrideConnection
- type UserOverrideResolver
- type UserOverrideSearchOptions
- type UserResolver
- type UserRole
- type UserSearchOptions
- type VerifyContactMethodInput
Constants ¶
This section is empty.
Variables ¶
View Source
var AllAlertStatus = []AlertStatus{ AlertStatusStatusAcknowledged, AlertStatusStatusClosed, AlertStatusStatusUnacknowledged, }
View Source
var AllConfigType = []ConfigType{ ConfigTypeString, ConfigTypeStringList, ConfigTypeInteger, ConfigTypeBoolean, }
View Source
var AllIntegrationKeyType = []IntegrationKeyType{ IntegrationKeyTypeGeneric, IntegrationKeyTypeGrafana, IntegrationKeyTypeSite24x7, IntegrationKeyTypeEmail, }
View Source
var AllUserRole = []UserRole{ UserRoleUnknown, UserRoleUser, UserRoleAdmin, }
Functions ¶
func ApplyConfigValues ¶
ApplyConfigValues will apply a list of ConfigValues to a Config struct.
func MarshalContactMethodType ¶
func MarshalContactMethodType(t contactmethod.Type) graphql.Marshaler
func NewExecutableSchema ¶
func NewExecutableSchema(cfg Config) graphql.ExecutableSchema
NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.
func UnmarshalClockTime ¶
func UnmarshalContactMethodType ¶
func UnmarshalContactMethodType(v interface{}) (contactmethod.Type, error)
func UnmarshalISOTimestamp ¶
Types ¶
type AlertConnection ¶
type AlertLogEntryConnection ¶ added in v0.23.0
type AlertLogEntryConnection struct { Nodes []alertlog.Entry `json:"nodes"` PageInfo PageInfo `json:"pageInfo"` }
type AlertLogEntryResolver ¶ added in v0.23.0
type AlertRecentEventsOptions ¶ added in v0.23.0
type AlertResolver ¶
type AlertResolver interface { AlertID(ctx context.Context, obj *alert.Alert) (int, error) Status(ctx context.Context, obj *alert.Alert) (AlertStatus, error) Service(ctx context.Context, obj *alert.Alert) (*service.Service, error) State(ctx context.Context, obj *alert.Alert) (*alert.State, error) RecentEvents(ctx context.Context, obj *alert.Alert, input *AlertRecentEventsOptions) (*AlertLogEntryConnection, error) }
type AlertSearchOptions ¶
type AlertStatus ¶
type AlertStatus string
const ( AlertStatusStatusAcknowledged AlertStatus = "StatusAcknowledged" AlertStatusStatusClosed AlertStatus = "StatusClosed" AlertStatusStatusUnacknowledged AlertStatus = "StatusUnacknowledged" )
func (AlertStatus) IsValid ¶
func (e AlertStatus) IsValid() bool
func (AlertStatus) MarshalGQL ¶
func (e AlertStatus) MarshalGQL(w io.Writer)
func (AlertStatus) String ¶
func (e AlertStatus) String() string
func (*AlertStatus) UnmarshalGQL ¶
func (e *AlertStatus) UnmarshalGQL(v interface{}) error
type AuthSubjectConnection ¶
type AuthSubjectConnection struct { Nodes []user.AuthSubject `json:"nodes"` PageInfo PageInfo `json:"pageInfo"` }
type ComplexityRoot ¶
type ComplexityRoot struct { Alert struct { AlertID func(childComplexity int) int CreatedAt func(childComplexity int) int Details func(childComplexity int) int ID func(childComplexity int) int RecentEvents func(childComplexity int, input *AlertRecentEventsOptions) int Service func(childComplexity int) int ServiceID func(childComplexity int) int State func(childComplexity int) int Status func(childComplexity int) int Summary func(childComplexity int) int } AlertConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } AlertLogEntry struct { ID func(childComplexity int) int Message func(childComplexity int) int Timestamp func(childComplexity int) int } AlertLogEntryConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } AlertState struct { LastEscalation func(childComplexity int) int RepeatCount func(childComplexity int) int StepNumber func(childComplexity int) int } AuthSubject struct { ProviderID func(childComplexity int) int SubjectID func(childComplexity int) int UserID func(childComplexity int) int } AuthSubjectConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } ConfigValue struct { Description func(childComplexity int) int ID func(childComplexity int) int Password func(childComplexity int) int Type func(childComplexity int) int Value func(childComplexity int) int } EscalationPolicy struct { AssignedTo func(childComplexity int) int Description func(childComplexity int) int ID func(childComplexity int) int Name func(childComplexity int) int Repeat func(childComplexity int) int Steps func(childComplexity int) int } EscalationPolicyConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } EscalationPolicyStep struct { DelayMinutes func(childComplexity int) int EscalationPolicy func(childComplexity int) int ID func(childComplexity int) int StepNumber func(childComplexity int) int Targets func(childComplexity int) int } HeartbeatMonitor struct { Href func(childComplexity int) int ID func(childComplexity int) int LastHeartbeat func(childComplexity int) int LastState func(childComplexity int) int Name func(childComplexity int) int ServiceID func(childComplexity int) int TimeoutMinutes func(childComplexity int) int } IntegrationKey struct { Href func(childComplexity int) int ID func(childComplexity int) int Name func(childComplexity int) int ServiceID func(childComplexity int) int Type func(childComplexity int) int } Label struct { Key func(childComplexity int) int Value func(childComplexity int) int } LabelConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } Mutation struct { AddAuthSubject func(childComplexity int, input user.AuthSubject) int CreateAlert func(childComplexity int, input CreateAlertInput) int CreateEscalationPolicy func(childComplexity int, input CreateEscalationPolicyInput) int CreateEscalationPolicyStep func(childComplexity int, input CreateEscalationPolicyStepInput) int CreateHeartbeatMonitor func(childComplexity int, input CreateHeartbeatMonitorInput) int CreateIntegrationKey func(childComplexity int, input CreateIntegrationKeyInput) int CreateRotation func(childComplexity int, input CreateRotationInput) int CreateSchedule func(childComplexity int, input CreateScheduleInput) int CreateService func(childComplexity int, input CreateServiceInput) int CreateUserContactMethod func(childComplexity int, input CreateUserContactMethodInput) int CreateUserNotificationRule func(childComplexity int, input CreateUserNotificationRuleInput) int CreateUserOverride func(childComplexity int, input CreateUserOverrideInput) int DeleteAll func(childComplexity int, input []assignment.RawTarget) int DeleteAuthSubject func(childComplexity int, input user.AuthSubject) int EscalateAlerts func(childComplexity int, input []int) int SendContactMethodVerification func(childComplexity int, input SendContactMethodVerificationInput) int SetConfig func(childComplexity int, input []ConfigValueInput) int SetFavorite func(childComplexity int, input SetFavoriteInput) int SetLabel func(childComplexity int, input SetLabelInput) int TestContactMethod func(childComplexity int, id string) int UpdateAlerts func(childComplexity int, input UpdateAlertsInput) int UpdateEscalationPolicy func(childComplexity int, input UpdateEscalationPolicyInput) int UpdateEscalationPolicyStep func(childComplexity int, input UpdateEscalationPolicyStepInput) int UpdateHeartbeatMonitor func(childComplexity int, input UpdateHeartbeatMonitorInput) int UpdateRotation func(childComplexity int, input UpdateRotationInput) int UpdateSchedule func(childComplexity int, input UpdateScheduleInput) int UpdateScheduleTarget func(childComplexity int, input ScheduleTargetInput) int UpdateService func(childComplexity int, input UpdateServiceInput) int UpdateUser func(childComplexity int, input UpdateUserInput) int UpdateUserContactMethod func(childComplexity int, input UpdateUserContactMethodInput) int UpdateUserOverride func(childComplexity int, input UpdateUserOverrideInput) int VerifyContactMethod func(childComplexity int, input VerifyContactMethodInput) int } OnCallShift struct { End func(childComplexity int) int Start func(childComplexity int) int Truncated func(childComplexity int) int User func(childComplexity int) int UserID func(childComplexity int) int } PageInfo struct { EndCursor func(childComplexity int) int HasNextPage func(childComplexity int) int } Query struct { Alert func(childComplexity int, id int) int Alerts func(childComplexity int, input *AlertSearchOptions) int AuthSubjectsForProvider func(childComplexity int, first *int, after *string, providerID string) int Config func(childComplexity int, all *bool) int EscalationPolicies func(childComplexity int, input *EscalationPolicySearchOptions) int EscalationPolicy func(childComplexity int, id string) int HeartbeatMonitor func(childComplexity int, id string) int IntegrationKey func(childComplexity int, id string) int Labels func(childComplexity int, input *LabelSearchOptions) int Rotation func(childComplexity int, id string) int Rotations func(childComplexity int, input *RotationSearchOptions) int Schedule func(childComplexity int, id string) int Schedules func(childComplexity int, input *ScheduleSearchOptions) int Service func(childComplexity int, id string) int Services func(childComplexity int, input *ServiceSearchOptions) int SlackChannel func(childComplexity int, id string) int SlackChannels func(childComplexity int, input *SlackChannelSearchOptions) int TimeZones func(childComplexity int, input *TimeZoneSearchOptions) int User func(childComplexity int, id *string) int UserContactMethod func(childComplexity int, id string) int UserOverride func(childComplexity int, id string) int UserOverrides func(childComplexity int, input *UserOverrideSearchOptions) int Users func(childComplexity int, input *UserSearchOptions, first *int, after *string, search *string) int } Rotation struct { ActiveUserIndex func(childComplexity int) int Description func(childComplexity int) int ID func(childComplexity int) int IsFavorite func(childComplexity int) int Name func(childComplexity int) int NextHandoffTimes func(childComplexity int, num *int) int ShiftLength func(childComplexity int) int Start func(childComplexity int) int TimeZone func(childComplexity int) int Type func(childComplexity int) int UserIDs func(childComplexity int) int Users func(childComplexity int) int } RotationConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } Schedule struct { AssignedTo func(childComplexity int) int Description func(childComplexity int) int ID func(childComplexity int) int IsFavorite func(childComplexity int) int Name func(childComplexity int) int Shifts func(childComplexity int, start time.Time, end time.Time) int Target func(childComplexity int, input assignment.RawTarget) int Targets func(childComplexity int) int TimeZone func(childComplexity int) int } ScheduleConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } ScheduleRule struct { End func(childComplexity int) int ID func(childComplexity int) int ScheduleID func(childComplexity int) int Start func(childComplexity int) int Target func(childComplexity int) int WeekdayFilter func(childComplexity int) int } ScheduleTarget struct { Rules func(childComplexity int) int ScheduleID func(childComplexity int) int Target func(childComplexity int) int } Service struct { Description func(childComplexity int) int EscalationPolicy func(childComplexity int) int EscalationPolicyID func(childComplexity int) int HeartbeatMonitors func(childComplexity int) int ID func(childComplexity int) int IntegrationKeys func(childComplexity int) int IsFavorite func(childComplexity int) int Labels func(childComplexity int) int Name func(childComplexity int) int OnCallUsers func(childComplexity int) int } ServiceConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } ServiceOnCallUser struct { StepNumber func(childComplexity int) int UserID func(childComplexity int) int UserName func(childComplexity int) int } SlackChannel struct { ID func(childComplexity int) int Name func(childComplexity int) int } SlackChannelConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } Target struct { ID func(childComplexity int) int Name func(childComplexity int) int Type func(childComplexity int) int } TimeZone struct { ID func(childComplexity int) int } TimeZoneConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } User struct { AlertStatusCMID func(childComplexity int) int AuthSubjects func(childComplexity int) int ContactMethods func(childComplexity int) int Email func(childComplexity int) int ID func(childComplexity int) int Name func(childComplexity int) int NotificationRules func(childComplexity int) int OnCallSteps func(childComplexity int) int Role func(childComplexity int) int } UserConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } UserContactMethod struct { Disabled func(childComplexity int) int FormattedValue func(childComplexity int) int ID func(childComplexity int) int Name func(childComplexity int) int Type func(childComplexity int) int Value func(childComplexity int) int } UserNotificationRule struct { ContactMethod func(childComplexity int) int ContactMethodID func(childComplexity int) int DelayMinutes func(childComplexity int) int ID func(childComplexity int) int } UserOverride struct { AddUser func(childComplexity int) int AddUserID func(childComplexity int) int End func(childComplexity int) int ID func(childComplexity int) int RemoveUser func(childComplexity int) int RemoveUserID func(childComplexity int) int Start func(childComplexity int) int Target func(childComplexity int) int } UserOverrideConnection struct { Nodes func(childComplexity int) int PageInfo func(childComplexity int) int } }
type Config ¶
type Config struct { Resolvers ResolverRoot Directives DirectiveRoot Complexity ComplexityRoot }
type ConfigType ¶
type ConfigType string
const ( ConfigTypeString ConfigType = "string" ConfigTypeStringList ConfigType = "stringList" ConfigTypeInteger ConfigType = "integer" ConfigTypeBoolean ConfigType = "boolean" )
func (ConfigType) IsValid ¶
func (e ConfigType) IsValid() bool
func (ConfigType) MarshalGQL ¶
func (e ConfigType) MarshalGQL(w io.Writer)
func (ConfigType) String ¶
func (e ConfigType) String() string
func (*ConfigType) UnmarshalGQL ¶
func (e *ConfigType) UnmarshalGQL(v interface{}) error
type ConfigValue ¶
type ConfigValue struct { ID string `json:"id"` Description string `json:"description"` Value string `json:"value"` Type ConfigType `json:"type"` Password bool `json:"password"` }
func MapConfigValues ¶
func MapConfigValues(cfg config.Config) []ConfigValue
MapConfigValues will map a Config struct into a flat list of ConfigValue structs.
func MapPublicConfigValues ¶
func MapPublicConfigValues(cfg config.Config) []ConfigValue
MapPublicConfigValues will map a Config struct into a flat list of ConfigValue structs.
type ConfigValueInput ¶
type CreateAlertInput ¶ added in v0.23.0
type CreateEscalationPolicyInput ¶
type CreateEscalationPolicyInput struct { Name string `json:"name"` Description *string `json:"description"` Repeat *int `json:"repeat"` Steps []CreateEscalationPolicyStepInput `json:"steps"` }
type CreateEscalationPolicyStepInput ¶
type CreateEscalationPolicyStepInput struct { EscalationPolicyID *string `json:"escalationPolicyID"` DelayMinutes int `json:"delayMinutes"` Targets []assignment.RawTarget `json:"targets"` NewRotation *CreateRotationInput `json:"newRotation"` NewSchedule *CreateScheduleInput `json:"newSchedule"` }
type CreateHeartbeatMonitorInput ¶ added in v0.24.0
type CreateIntegrationKeyInput ¶
type CreateIntegrationKeyInput struct { ServiceID *string `json:"serviceID"` Type IntegrationKeyType `json:"type"` Name string `json:"name"` }
type CreateRotationInput ¶
type CreateRotationInput struct { Name string `json:"name"` Description *string `json:"description"` TimeZone string `json:"timeZone"` Start time.Time `json:"start"` Favorite *bool `json:"favorite"` Type rotation.Type `json:"type"` ShiftLength *int `json:"shiftLength"` UserIDs []string `json:"userIDs"` }
type CreateScheduleInput ¶
type CreateScheduleInput struct { Name string `json:"name"` Description *string `json:"description"` TimeZone string `json:"timeZone"` Favorite *bool `json:"favorite"` Targets []ScheduleTargetInput `json:"targets"` }
type CreateServiceInput ¶
type CreateServiceInput struct { Name string `json:"name"` Description *string `json:"description"` Favorite *bool `json:"favorite"` EscalationPolicyID *string `json:"escalationPolicyID"` NewEscalationPolicy *CreateEscalationPolicyInput `json:"newEscalationPolicy"` NewIntegrationKeys []CreateIntegrationKeyInput `json:"newIntegrationKeys"` Labels []SetLabelInput `json:"labels"` NewHeartbeatMonitors []CreateHeartbeatMonitorInput `json:"newHeartbeatMonitors"` }
type CreateUserContactMethodInput ¶
type CreateUserContactMethodInput struct { UserID string `json:"userID"` Type contactmethod.Type `json:"type"` Name string `json:"name"` Value string `json:"value"` NewUserNotificationRule *CreateUserNotificationRuleInput `json:"newUserNotificationRule"` }
type CreateUserOverrideInput ¶
type DirectiveRoot ¶
type DirectiveRoot struct { }
type EscalationPolicyConnection ¶
type EscalationPolicyConnection struct { Nodes []escalation.Policy `json:"nodes"` PageInfo PageInfo `json:"pageInfo"` }
type EscalationPolicyResolver ¶
type EscalationPolicyResolver interface { AssignedTo(ctx context.Context, obj *escalation.Policy) ([]assignment.RawTarget, error) Steps(ctx context.Context, obj *escalation.Policy) ([]escalation.Step, error) }
type EscalationPolicyStepResolver ¶
type EscalationPolicyStepResolver interface { Targets(ctx context.Context, obj *escalation.Step) ([]assignment.RawTarget, error) EscalationPolicy(ctx context.Context, obj *escalation.Step) (*escalation.Policy, error) }
type HeartbeatMonitorResolver ¶ added in v0.24.0
type IntegrationKeyResolver ¶
type IntegrationKeyResolver interface { Type(ctx context.Context, obj *integrationkey.IntegrationKey) (IntegrationKeyType, error) Href(ctx context.Context, obj *integrationkey.IntegrationKey) (string, error) }
type IntegrationKeyType ¶
type IntegrationKeyType string
const ( IntegrationKeyTypeGeneric IntegrationKeyType = "generic" IntegrationKeyTypeGrafana IntegrationKeyType = "grafana" IntegrationKeyTypeSite24x7 IntegrationKeyType = "site24x7" IntegrationKeyTypeEmail IntegrationKeyType = "email" )
func (IntegrationKeyType) IsValid ¶
func (e IntegrationKeyType) IsValid() bool
func (IntegrationKeyType) MarshalGQL ¶
func (e IntegrationKeyType) MarshalGQL(w io.Writer)
func (IntegrationKeyType) String ¶
func (e IntegrationKeyType) String() string
func (*IntegrationKeyType) UnmarshalGQL ¶
func (e *IntegrationKeyType) UnmarshalGQL(v interface{}) error
type LabelConnection ¶
type LabelSearchOptions ¶
type MutationResolver ¶
type MutationResolver interface { AddAuthSubject(ctx context.Context, input user.AuthSubject) (bool, error) DeleteAuthSubject(ctx context.Context, input user.AuthSubject) (bool, error) UpdateUser(ctx context.Context, input UpdateUserInput) (bool, error) TestContactMethod(ctx context.Context, id string) (bool, error) UpdateAlerts(ctx context.Context, input UpdateAlertsInput) ([]alert.Alert, error) UpdateRotation(ctx context.Context, input UpdateRotationInput) (bool, error) EscalateAlerts(ctx context.Context, input []int) ([]alert.Alert, error) SetFavorite(ctx context.Context, input SetFavoriteInput) (bool, error) UpdateService(ctx context.Context, input UpdateServiceInput) (bool, error) UpdateEscalationPolicy(ctx context.Context, input UpdateEscalationPolicyInput) (bool, error) UpdateEscalationPolicyStep(ctx context.Context, input UpdateEscalationPolicyStepInput) (bool, error) DeleteAll(ctx context.Context, input []assignment.RawTarget) (bool, error) CreateAlert(ctx context.Context, input CreateAlertInput) (*alert.Alert, error) CreateService(ctx context.Context, input CreateServiceInput) (*service.Service, error) CreateEscalationPolicy(ctx context.Context, input CreateEscalationPolicyInput) (*escalation.Policy, error) CreateEscalationPolicyStep(ctx context.Context, input CreateEscalationPolicyStepInput) (*escalation.Step, error) CreateRotation(ctx context.Context, input CreateRotationInput) (*rotation.Rotation, error) CreateIntegrationKey(ctx context.Context, input CreateIntegrationKeyInput) (*integrationkey.IntegrationKey, error) CreateHeartbeatMonitor(ctx context.Context, input CreateHeartbeatMonitorInput) (*heartbeat.Monitor, error) SetLabel(ctx context.Context, input SetLabelInput) (bool, error) CreateSchedule(ctx context.Context, input CreateScheduleInput) (*schedule.Schedule, error) UpdateScheduleTarget(ctx context.Context, input ScheduleTargetInput) (bool, error) CreateUserOverride(ctx context.Context, input CreateUserOverrideInput) (*override.UserOverride, error) CreateUserContactMethod(ctx context.Context, input CreateUserContactMethodInput) (*contactmethod.ContactMethod, error) CreateUserNotificationRule(ctx context.Context, input CreateUserNotificationRuleInput) (*notificationrule.NotificationRule, error) UpdateUserContactMethod(ctx context.Context, input UpdateUserContactMethodInput) (bool, error) SendContactMethodVerification(ctx context.Context, input SendContactMethodVerificationInput) (bool, error) VerifyContactMethod(ctx context.Context, input VerifyContactMethodInput) (bool, error) UpdateSchedule(ctx context.Context, input UpdateScheduleInput) (bool, error) UpdateUserOverride(ctx context.Context, input UpdateUserOverrideInput) (bool, error) UpdateHeartbeatMonitor(ctx context.Context, input UpdateHeartbeatMonitorInput) (bool, error) SetConfig(ctx context.Context, input []ConfigValueInput) (bool, error) }
type OnCallShiftResolver ¶
type QueryResolver ¶
type QueryResolver interface { User(ctx context.Context, id *string) (*user.User, error) Users(ctx context.Context, input *UserSearchOptions, first *int, after *string, search *string) (*UserConnection, error) Alert(ctx context.Context, id int) (*alert.Alert, error) Alerts(ctx context.Context, input *AlertSearchOptions) (*AlertConnection, error) Service(ctx context.Context, id string) (*service.Service, error) IntegrationKey(ctx context.Context, id string) (*integrationkey.IntegrationKey, error) HeartbeatMonitor(ctx context.Context, id string) (*heartbeat.Monitor, error) Services(ctx context.Context, input *ServiceSearchOptions) (*ServiceConnection, error) Rotation(ctx context.Context, id string) (*rotation.Rotation, error) Rotations(ctx context.Context, input *RotationSearchOptions) (*RotationConnection, error) Schedule(ctx context.Context, id string) (*schedule.Schedule, error) Schedules(ctx context.Context, input *ScheduleSearchOptions) (*ScheduleConnection, error) EscalationPolicy(ctx context.Context, id string) (*escalation.Policy, error) EscalationPolicies(ctx context.Context, input *EscalationPolicySearchOptions) (*EscalationPolicyConnection, error) AuthSubjectsForProvider(ctx context.Context, first *int, after *string, providerID string) (*AuthSubjectConnection, error) TimeZones(ctx context.Context, input *TimeZoneSearchOptions) (*TimeZoneConnection, error) Labels(ctx context.Context, input *LabelSearchOptions) (*LabelConnection, error) UserOverrides(ctx context.Context, input *UserOverrideSearchOptions) (*UserOverrideConnection, error) UserOverride(ctx context.Context, id string) (*override.UserOverride, error) Config(ctx context.Context, all *bool) ([]ConfigValue, error) UserContactMethod(ctx context.Context, id string) (*contactmethod.ContactMethod, error) SlackChannels(ctx context.Context, input *SlackChannelSearchOptions) (*SlackChannelConnection, error) SlackChannel(ctx context.Context, id string) (*slack.Channel, error) }
type ResolverRoot ¶
type ResolverRoot interface { Alert() AlertResolver AlertLogEntry() AlertLogEntryResolver EscalationPolicy() EscalationPolicyResolver EscalationPolicyStep() EscalationPolicyStepResolver HeartbeatMonitor() HeartbeatMonitorResolver IntegrationKey() IntegrationKeyResolver Mutation() MutationResolver OnCallShift() OnCallShiftResolver Query() QueryResolver Rotation() RotationResolver Schedule() ScheduleResolver ScheduleRule() ScheduleRuleResolver Service() ServiceResolver Target() TargetResolver User() UserResolver UserContactMethod() UserContactMethodResolver UserNotificationRule() UserNotificationRuleResolver UserOverride() UserOverrideResolver }
type RotationConnection ¶
type RotationResolver ¶
type RotationResolver interface { IsFavorite(ctx context.Context, obj *rotation.Rotation) (bool, error) TimeZone(ctx context.Context, obj *rotation.Rotation) (string, error) ActiveUserIndex(ctx context.Context, obj *rotation.Rotation) (int, error) UserIDs(ctx context.Context, obj *rotation.Rotation) ([]string, error) Users(ctx context.Context, obj *rotation.Rotation) ([]user.User, error) NextHandoffTimes(ctx context.Context, obj *rotation.Rotation, num *int) ([]time.Time, error) }
type RotationSearchOptions ¶
type ScheduleConnection ¶
type ScheduleResolver ¶
type ScheduleResolver interface { TimeZone(ctx context.Context, obj *schedule.Schedule) (string, error) AssignedTo(ctx context.Context, obj *schedule.Schedule) ([]assignment.RawTarget, error) Shifts(ctx context.Context, obj *schedule.Schedule, start time.Time, end time.Time) ([]oncall.Shift, error) Targets(ctx context.Context, obj *schedule.Schedule) ([]ScheduleTarget, error) Target(ctx context.Context, obj *schedule.Schedule, input assignment.RawTarget) (*ScheduleTarget, error) IsFavorite(ctx context.Context, obj *schedule.Schedule) (bool, error) }
type ScheduleRuleInput ¶
type ScheduleRuleResolver ¶
type ScheduleSearchOptions ¶
type ScheduleTarget ¶
type ScheduleTarget struct { ScheduleID string `json:"scheduleID"` Target assignment.RawTarget `json:"target"` Rules []rule.Rule `json:"rules"` }
type ScheduleTargetInput ¶
type ScheduleTargetInput struct { ScheduleID *string `json:"scheduleID"` Target *assignment.RawTarget `json:"target"` NewRotation *CreateRotationInput `json:"newRotation"` Rules []ScheduleRuleInput `json:"rules"` }
type SendContactMethodVerificationInput ¶ added in v0.23.0
type SendContactMethodVerificationInput struct {
ContactMethodID string `json:"contactMethodID"`
}
type ServiceConnection ¶
type ServiceResolver ¶
type ServiceResolver interface { EscalationPolicy(ctx context.Context, obj *service.Service) (*escalation.Policy, error) IsFavorite(ctx context.Context, obj *service.Service) (bool, error) OnCallUsers(ctx context.Context, obj *service.Service) ([]oncall.ServiceOnCallUser, error) IntegrationKeys(ctx context.Context, obj *service.Service) ([]integrationkey.IntegrationKey, error) Labels(ctx context.Context, obj *service.Service) ([]label.Label, error) HeartbeatMonitors(ctx context.Context, obj *service.Service) ([]heartbeat.Monitor, error) }
type ServiceSearchOptions ¶
type SetFavoriteInput ¶
type SetFavoriteInput struct { Target assignment.RawTarget `json:"target"` Favorite bool `json:"favorite"` }
type SetLabelInput ¶
type SetLabelInput struct { Target *assignment.RawTarget `json:"target"` Key string `json:"key"` Value string `json:"value"` }
type SlackChannelConnection ¶
type TargetResolver ¶
type TimeZoneConnection ¶
type TimeZoneSearchOptions ¶
type UpdateAlertsInput ¶
type UpdateAlertsInput struct { AlertIDs []int `json:"alertIDs"` NewStatus AlertStatus `json:"newStatus"` }
type UpdateEscalationPolicyStepInput ¶
type UpdateEscalationPolicyStepInput struct { ID string `json:"id"` DelayMinutes *int `json:"delayMinutes"` Targets []assignment.RawTarget `json:"targets"` }
type UpdateHeartbeatMonitorInput ¶ added in v0.24.0
type UpdateRotationInput ¶
type UpdateRotationInput struct { ID string `json:"id"` Name *string `json:"name"` Description *string `json:"description"` TimeZone *string `json:"timeZone"` Start *time.Time `json:"start"` Type *rotation.Type `json:"type"` ShiftLength *int `json:"shiftLength"` ActiveUserIndex *int `json:"activeUserIndex"` UserIDs []string `json:"userIDs"` }
type UpdateScheduleInput ¶
type UpdateServiceInput ¶
type UpdateUserInput ¶
type UpdateUserOverrideInput ¶
type UserConnection ¶
type UserContactMethodResolver ¶ added in v0.23.0
type UserContactMethodResolver interface {
FormattedValue(ctx context.Context, obj *contactmethod.ContactMethod) (string, error)
}
type UserNotificationRuleResolver ¶
type UserNotificationRuleResolver interface {
ContactMethod(ctx context.Context, obj *notificationrule.NotificationRule) (*contactmethod.ContactMethod, error)
}
type UserOverrideConnection ¶
type UserOverrideConnection struct { Nodes []override.UserOverride `json:"nodes"` PageInfo PageInfo `json:"pageInfo"` }
type UserOverrideResolver ¶
type UserOverrideSearchOptions ¶
type UserOverrideSearchOptions struct { First *int `json:"first"` After *string `json:"after"` Omit []string `json:"omit"` ScheduleID *string `json:"scheduleID"` FilterAddUserID []string `json:"filterAddUserID"` FilterRemoveUserID []string `json:"filterRemoveUserID"` FilterAnyUserID []string `json:"filterAnyUserID"` Start *time.Time `json:"start"` End *time.Time `json:"end"` }
type UserResolver ¶
type UserResolver interface { Role(ctx context.Context, obj *user.User) (UserRole, error) ContactMethods(ctx context.Context, obj *user.User) ([]contactmethod.ContactMethod, error) NotificationRules(ctx context.Context, obj *user.User) ([]notificationrule.NotificationRule, error) AuthSubjects(ctx context.Context, obj *user.User) ([]user.AuthSubject, error) OnCallSteps(ctx context.Context, obj *user.User) ([]escalation.Step, error) }
type UserSearchOptions ¶
type VerifyContactMethodInput ¶ added in v0.23.0
Source Files ¶
Click to show internal directories.
Click to hide internal directories.