Documentation
¶
Index ¶
- Constants
- Variables
- func RegisterConfigurerServer(s grpc.ServiceRegistrar, srv ConfigurerServer)
- func RegisterDisplayerServer(s grpc.ServiceRegistrar, srv DisplayerServer)
- func RegisterPluginServer(s grpc.ServiceRegistrar, srv PluginServer)
- func RegisterServerEventReceiverServer(s grpc.ServiceRegistrar, srv ServerEventReceiverServer)
- type Capabilities
- func (*Capabilities) Descriptor() ([]byte, []int)deprecated
- func (x *Capabilities) GetConfigurer() uint32
- func (x *Capabilities) GetDisplayer() uint32
- func (x *Capabilities) GetWebhooker() uint32
- func (*Capabilities) ProtoMessage()
- func (x *Capabilities) ProtoReflect() protoreflect.Message
- func (x *Capabilities) Reset()
- func (x *Capabilities) String() string
- type Capability
- type Config
- type ConfigurerClient
- type ConfigurerServer
- type DefaultConfigRequest
- func (*DefaultConfigRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DefaultConfigRequest) GetUser() *UserContext
- func (*DefaultConfigRequest) ProtoMessage()
- func (x *DefaultConfigRequest) ProtoReflect() protoreflect.Message
- func (x *DefaultConfigRequest) Reset()
- func (x *DefaultConfigRequest) String() string
- type DisplayRequest
- func (*DisplayRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DisplayRequest) GetLocation() string
- func (x *DisplayRequest) GetUser() *UserContext
- func (*DisplayRequest) ProtoMessage()
- func (x *DisplayRequest) ProtoReflect() protoreflect.Message
- func (x *DisplayRequest) Reset()
- func (x *DisplayRequest) String() string
- type DisplayResponse
- func (*DisplayResponse) Descriptor() ([]byte, []int)deprecated
- func (x *DisplayResponse) GetMarkdown() string
- func (x *DisplayResponse) GetResponse() isDisplayResponse_Response
- func (*DisplayResponse) ProtoMessage()
- func (x *DisplayResponse) ProtoReflect() protoreflect.Message
- func (x *DisplayResponse) Reset()
- func (x *DisplayResponse) String() string
- type DisplayResponse_Markdown
- type DisplayerClient
- type DisplayerServer
- type Error
- type ExtrasValue
- func (*ExtrasValue) Descriptor() ([]byte, []int)deprecated
- func (x *ExtrasValue) GetJson() string
- func (x *ExtrasValue) GetValue() isExtrasValue_Value
- func (*ExtrasValue) ProtoMessage()
- func (x *ExtrasValue) ProtoReflect() protoreflect.Message
- func (x *ExtrasValue) Reset()
- func (x *ExtrasValue) String() string
- type ExtrasValue_Json
- type Info
- func (*Info) Descriptor() ([]byte, []int)deprecated
- func (x *Info) GetAuthor() string
- func (x *Info) GetCapabilities() *Capabilities
- func (x *Info) GetDescription() string
- func (x *Info) GetLicense() string
- func (x *Info) GetModulePath() string
- func (x *Info) GetName() string
- func (x *Info) GetVersion() string
- func (x *Info) GetWebsite() string
- func (*Info) ProtoMessage()
- func (x *Info) ProtoReflect() protoreflect.Message
- func (x *Info) Reset()
- func (x *Info) String() string
- type InstanceUpdate
- func (*InstanceUpdate) Descriptor() ([]byte, []int)deprecated
- func (x *InstanceUpdate) GetCapable() Capability
- func (x *InstanceUpdate) GetMessage() *Message
- func (x *InstanceUpdate) GetPing() *emptypb.Empty
- func (x *InstanceUpdate) GetStorage() []byte
- func (x *InstanceUpdate) GetUpdate() isInstanceUpdate_Update
- func (*InstanceUpdate) ProtoMessage()
- func (x *InstanceUpdate) ProtoReflect() protoreflect.Message
- func (x *InstanceUpdate) Reset()
- func (x *InstanceUpdate) String() string
- type InstanceUpdate_Capable
- type InstanceUpdate_Message
- type InstanceUpdate_Ping
- type InstanceUpdate_Storage
- type Message
- func (*Message) Descriptor() ([]byte, []int)deprecated
- func (x *Message) GetExtras() map[string]*ExtrasValue
- func (x *Message) GetMessage() string
- func (x *Message) GetPriority() int32
- func (x *Message) GetTitle() string
- func (*Message) ProtoMessage()
- func (x *Message) ProtoReflect() protoreflect.Message
- func (x *Message) Reset()
- func (x *Message) String() string
- type PluginClient
- type PluginServer
- type Plugin_RunUserInstanceClient
- type Plugin_RunUserInstanceServer
- type ServerEvent
- func (*ServerEvent) Descriptor() ([]byte, []int)deprecated
- func (x *ServerEvent) GetEvent() isServerEvent_Event
- func (x *ServerEvent) GetUser() *UserContext
- func (*ServerEvent) ProtoMessage()
- func (x *ServerEvent) ProtoReflect() protoreflect.Message
- func (x *ServerEvent) Reset()
- func (x *ServerEvent) String() string
- type ServerEventReceiverClient
- type ServerEventReceiverServer
- type ServerEventReceiver_ServerEventsClient
- type ServerEventReceiver_ServerEventsServer
- type ServerEvent_User
- type ServerInfo
- func (*ServerInfo) Descriptor() ([]byte, []int)deprecated
- func (x *ServerInfo) GetBuildDate() string
- func (x *ServerInfo) GetCapabilities() []Capability
- func (x *ServerInfo) GetCommit() string
- func (x *ServerInfo) GetVersion() string
- func (*ServerInfo) ProtoMessage()
- func (x *ServerInfo) ProtoReflect() protoreflect.Message
- func (x *ServerInfo) Reset()
- func (x *ServerInfo) String() string
- type UnimplementedConfigurerServer
- type UnimplementedDisplayerServer
- type UnimplementedPluginServer
- func (UnimplementedPluginServer) GetPluginInfo(context.Context, *emptypb.Empty) (*Info, error)
- func (UnimplementedPluginServer) GracefulShutdown(context.Context, *emptypb.Empty) (*emptypb.Empty, error)
- func (UnimplementedPluginServer) RunUserInstance(*UserInstanceRequest, grpc.ServerStreamingServer[InstanceUpdate]) error
- type UnimplementedServerEventReceiverServer
- type UnsafeConfigurerServer
- type UnsafeDisplayerServer
- type UnsafePluginServer
- type UnsafeServerEventReceiverServer
- type UserContext
- func (*UserContext) Descriptor() ([]byte, []int)deprecated
- func (x *UserContext) GetAdmin() bool
- func (x *UserContext) GetId() uint64
- func (x *UserContext) GetName() string
- func (*UserContext) ProtoMessage()
- func (x *UserContext) ProtoReflect() protoreflect.Message
- func (x *UserContext) Reset()
- func (x *UserContext) String() string
- type UserInstanceRequest
- func (*UserInstanceRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UserInstanceRequest) GetConfig() []byte
- func (x *UserInstanceRequest) GetServerInfo() *ServerInfo
- func (x *UserInstanceRequest) GetStorage() []byte
- func (x *UserInstanceRequest) GetUser() *UserContext
- func (x *UserInstanceRequest) GetWebhookBasePath() string
- func (*UserInstanceRequest) ProtoMessage()
- func (x *UserInstanceRequest) ProtoReflect() protoreflect.Message
- func (x *UserInstanceRequest) Reset()
- func (x *UserInstanceRequest) String() string
- type ValidateAndSetConfigRequest
- func (*ValidateAndSetConfigRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ValidateAndSetConfigRequest) GetConfig() *Config
- func (x *ValidateAndSetConfigRequest) GetUser() *UserContext
- func (*ValidateAndSetConfigRequest) ProtoMessage()
- func (x *ValidateAndSetConfigRequest) ProtoReflect() protoreflect.Message
- func (x *ValidateAndSetConfigRequest) Reset()
- func (x *ValidateAndSetConfigRequest) String() string
- type ValidateAndSetConfigResponse
- func (*ValidateAndSetConfigResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ValidateAndSetConfigResponse) GetResponse() isValidateAndSetConfigResponse_Response
- func (x *ValidateAndSetConfigResponse) GetSuccess() *emptypb.Empty
- func (x *ValidateAndSetConfigResponse) GetValidationError() *Error
- func (*ValidateAndSetConfigResponse) ProtoMessage()
- func (x *ValidateAndSetConfigResponse) ProtoReflect() protoreflect.Message
- func (x *ValidateAndSetConfigResponse) Reset()
- func (x *ValidateAndSetConfigResponse) String() string
- type ValidateAndSetConfigResponse_Success
- type ValidateAndSetConfigResponse_ValidationError
Constants ¶
const ( Configurer_DefaultConfig_FullMethodName = "/Configurer/DefaultConfig" Configurer_ValidateAndSetConfig_FullMethodName = "/Configurer/ValidateAndSetConfig" )
const ( Plugin_GetPluginInfo_FullMethodName = "/Plugin/GetPluginInfo" Plugin_GracefulShutdown_FullMethodName = "/Plugin/GracefulShutdown" Plugin_RunUserInstance_FullMethodName = "/Plugin/RunUserInstance" )
const (
Displayer_Display_FullMethodName = "/Displayer/Display"
)
const (
ServerEventReceiver_ServerEvents_FullMethodName = "/ServerEventReceiver/ServerEvents"
)
Variables ¶
var ( Capability_name = map[int32]string{ 0: "DISPLAYER", 1: "MESSENGER", 2: "CONFIGURER", 3: "STORAGER", 4: "WEBHOOKER", } Capability_value = map[string]int32{ "DISPLAYER": 0, "MESSENGER": 1, "CONFIGURER": 2, "STORAGER": 3, "WEBHOOKER": 4, } )
Enum value maps for Capability.
var Configurer_ServiceDesc = grpc.ServiceDesc{ ServiceName: "Configurer", HandlerType: (*ConfigurerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "DefaultConfig", Handler: _Configurer_DefaultConfig_Handler, }, { MethodName: "ValidateAndSetConfig", Handler: _Configurer_ValidateAndSetConfig_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "config.proto", }
Configurer_ServiceDesc is the grpc.ServiceDesc for Configurer service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var Displayer_ServiceDesc = grpc.ServiceDesc{ ServiceName: "Displayer", HandlerType: (*DisplayerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Display", Handler: _Displayer_Display_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "display.proto", }
Displayer_ServiceDesc is the grpc.ServiceDesc for Displayer service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_config_proto protoreflect.FileDescriptor
var File_display_proto protoreflect.FileDescriptor
var File_meta_proto protoreflect.FileDescriptor
var File_server_events_proto protoreflect.FileDescriptor
var Plugin_ServiceDesc = grpc.ServiceDesc{ ServiceName: "Plugin", HandlerType: (*PluginServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GetPluginInfo", Handler: _Plugin_GetPluginInfo_Handler, }, { MethodName: "GracefulShutdown", Handler: _Plugin_GracefulShutdown_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "RunUserInstance", Handler: _Plugin_RunUserInstance_Handler, ServerStreams: true, }, }, Metadata: "meta.proto", }
Plugin_ServiceDesc is the grpc.ServiceDesc for Plugin service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var ServerEventReceiver_ServiceDesc = grpc.ServiceDesc{ ServiceName: "ServerEventReceiver", HandlerType: (*ServerEventReceiverServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "ServerEvents", Handler: _ServerEventReceiver_ServerEvents_Handler, ClientStreams: true, }, }, Metadata: "server_events.proto", }
ServerEventReceiver_ServiceDesc is the grpc.ServiceDesc for ServerEventReceiver service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterConfigurerServer ¶
func RegisterConfigurerServer(s grpc.ServiceRegistrar, srv ConfigurerServer)
func RegisterDisplayerServer ¶
func RegisterDisplayerServer(s grpc.ServiceRegistrar, srv DisplayerServer)
func RegisterPluginServer ¶
func RegisterPluginServer(s grpc.ServiceRegistrar, srv PluginServer)
func RegisterServerEventReceiverServer ¶
func RegisterServerEventReceiverServer(s grpc.ServiceRegistrar, srv ServerEventReceiverServer)
Types ¶
type Capabilities ¶
type Capabilities struct {
Displayer *uint32 `protobuf:"varint,1,opt,name=Displayer,proto3,oneof" json:"Displayer,omitempty"`
Configurer *uint32 `protobuf:"varint,2,opt,name=Configurer,proto3,oneof" json:"Configurer,omitempty"`
Webhooker *uint32 `protobuf:"varint,3,opt,name=Webhooker,proto3,oneof" json:"Webhooker,omitempty"`
// contains filtered or unexported fields
}
func (*Capabilities) Descriptor
deprecated
func (*Capabilities) Descriptor() ([]byte, []int)
Deprecated: Use Capabilities.ProtoReflect.Descriptor instead.
func (*Capabilities) GetConfigurer ¶
func (x *Capabilities) GetConfigurer() uint32
func (*Capabilities) GetDisplayer ¶
func (x *Capabilities) GetDisplayer() uint32
func (*Capabilities) GetWebhooker ¶
func (x *Capabilities) GetWebhooker() uint32
func (*Capabilities) ProtoMessage ¶
func (*Capabilities) ProtoMessage()
func (*Capabilities) ProtoReflect ¶
func (x *Capabilities) ProtoReflect() protoreflect.Message
func (*Capabilities) Reset ¶
func (x *Capabilities) Reset()
func (*Capabilities) String ¶
func (x *Capabilities) String() string
type Capability ¶
type Capability int32
const ( Capability_DISPLAYER Capability = 0 Capability_MESSENGER Capability = 1 Capability_CONFIGURER Capability = 2 Capability_STORAGER Capability = 3 Capability_WEBHOOKER Capability = 4 )
func (Capability) Descriptor ¶
func (Capability) Descriptor() protoreflect.EnumDescriptor
func (Capability) Enum ¶
func (x Capability) Enum() *Capability
func (Capability) EnumDescriptor
deprecated
func (Capability) EnumDescriptor() ([]byte, []int)
Deprecated: Use Capability.Descriptor instead.
func (Capability) Number ¶
func (x Capability) Number() protoreflect.EnumNumber
func (Capability) String ¶
func (x Capability) String() string
func (Capability) Type ¶
func (Capability) Type() protoreflect.EnumType
type Config ¶
type Config struct {
// The YAML configuration data.
Config string `protobuf:"bytes,1,opt,name=config,proto3" json:"config,omitempty"`
// contains filtered or unexported fields
}
func (*Config) Descriptor
deprecated
func (*Config) ProtoMessage ¶
func (*Config) ProtoMessage()
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
type ConfigurerClient ¶
type ConfigurerClient interface {
DefaultConfig(ctx context.Context, in *DefaultConfigRequest, opts ...grpc.CallOption) (*Config, error)
ValidateAndSetConfig(ctx context.Context, in *ValidateAndSetConfigRequest, opts ...grpc.CallOption) (*ValidateAndSetConfigResponse, error)
}
ConfigurerClient is the client API for Configurer service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
A service that allows plugins to be configured through the Gotify server.
func NewConfigurerClient ¶
func NewConfigurerClient(cc grpc.ClientConnInterface) ConfigurerClient
type ConfigurerServer ¶
type ConfigurerServer interface {
DefaultConfig(context.Context, *DefaultConfigRequest) (*Config, error)
ValidateAndSetConfig(context.Context, *ValidateAndSetConfigRequest) (*ValidateAndSetConfigResponse, error)
// contains filtered or unexported methods
}
ConfigurerServer is the server API for Configurer service. All implementations must embed UnimplementedConfigurerServer for forward compatibility.
A service that allows plugins to be configured through the Gotify server.
type DefaultConfigRequest ¶
type DefaultConfigRequest struct {
// The user context the configuration belongs to.
User *UserContext `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
// contains filtered or unexported fields
}
func (*DefaultConfigRequest) Descriptor
deprecated
func (*DefaultConfigRequest) Descriptor() ([]byte, []int)
Deprecated: Use DefaultConfigRequest.ProtoReflect.Descriptor instead.
func (*DefaultConfigRequest) GetUser ¶
func (x *DefaultConfigRequest) GetUser() *UserContext
func (*DefaultConfigRequest) ProtoMessage ¶
func (*DefaultConfigRequest) ProtoMessage()
func (*DefaultConfigRequest) ProtoReflect ¶
func (x *DefaultConfigRequest) ProtoReflect() protoreflect.Message
func (*DefaultConfigRequest) Reset ¶
func (x *DefaultConfigRequest) Reset()
func (*DefaultConfigRequest) String ¶
func (x *DefaultConfigRequest) String() string
type DisplayRequest ¶
type DisplayRequest struct {
// The user context the display belongs to.
User *UserContext `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
// The base URL of the plugin control panel.
Location string `protobuf:"bytes,2,opt,name=location,proto3" json:"location,omitempty"`
// contains filtered or unexported fields
}
func (*DisplayRequest) Descriptor
deprecated
func (*DisplayRequest) Descriptor() ([]byte, []int)
Deprecated: Use DisplayRequest.ProtoReflect.Descriptor instead.
func (*DisplayRequest) GetLocation ¶
func (x *DisplayRequest) GetLocation() string
func (*DisplayRequest) GetUser ¶
func (x *DisplayRequest) GetUser() *UserContext
func (*DisplayRequest) ProtoMessage ¶
func (*DisplayRequest) ProtoMessage()
func (*DisplayRequest) ProtoReflect ¶
func (x *DisplayRequest) ProtoReflect() protoreflect.Message
func (*DisplayRequest) Reset ¶
func (x *DisplayRequest) Reset()
func (*DisplayRequest) String ¶
func (x *DisplayRequest) String() string
type DisplayResponse ¶
type DisplayResponse struct {
// Types that are valid to be assigned to Response:
//
// *DisplayResponse_Markdown
Response isDisplayResponse_Response `protobuf_oneof:"response"`
// contains filtered or unexported fields
}
func (*DisplayResponse) Descriptor
deprecated
func (*DisplayResponse) Descriptor() ([]byte, []int)
Deprecated: Use DisplayResponse.ProtoReflect.Descriptor instead.
func (*DisplayResponse) GetMarkdown ¶
func (x *DisplayResponse) GetMarkdown() string
func (*DisplayResponse) GetResponse ¶
func (x *DisplayResponse) GetResponse() isDisplayResponse_Response
func (*DisplayResponse) ProtoMessage ¶
func (*DisplayResponse) ProtoMessage()
func (*DisplayResponse) ProtoReflect ¶
func (x *DisplayResponse) ProtoReflect() protoreflect.Message
func (*DisplayResponse) Reset ¶
func (x *DisplayResponse) Reset()
func (*DisplayResponse) String ¶
func (x *DisplayResponse) String() string
type DisplayResponse_Markdown ¶
type DisplayResponse_Markdown struct {
// The display response in markdown format.
Markdown string `protobuf:"bytes,1,opt,name=markdown,proto3,oneof"`
}
type DisplayerClient ¶
type DisplayerClient interface {
Display(ctx context.Context, in *DisplayRequest, opts ...grpc.CallOption) (*DisplayResponse, error)
}
DisplayerClient is the client API for Displayer service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
A service that allows plugins to display content to the user.
func NewDisplayerClient ¶
func NewDisplayerClient(cc grpc.ClientConnInterface) DisplayerClient
type DisplayerServer ¶
type DisplayerServer interface {
Display(context.Context, *DisplayRequest) (*DisplayResponse, error)
// contains filtered or unexported methods
}
DisplayerServer is the server API for Displayer service. All implementations must embed UnimplementedDisplayerServer for forward compatibility.
A service that allows plugins to display content to the user.
type Error ¶
type Error struct {
Details *anypb.Any `protobuf:"bytes,1,opt,name=details,proto3" json:"details,omitempty"`
Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
// contains filtered or unexported fields
}
func (*Error) Descriptor
deprecated
func (*Error) GetDetails ¶
func (*Error) GetMessage ¶
func (*Error) ProtoMessage ¶
func (*Error) ProtoMessage()
func (*Error) ProtoReflect ¶
func (x *Error) ProtoReflect() protoreflect.Message
type ExtrasValue ¶
type ExtrasValue struct {
// Types that are valid to be assigned to Value:
//
// *ExtrasValue_Json
Value isExtrasValue_Value `protobuf_oneof:"value"`
// contains filtered or unexported fields
}
func (*ExtrasValue) Descriptor
deprecated
func (*ExtrasValue) Descriptor() ([]byte, []int)
Deprecated: Use ExtrasValue.ProtoReflect.Descriptor instead.
func (*ExtrasValue) GetJson ¶
func (x *ExtrasValue) GetJson() string
func (*ExtrasValue) GetValue ¶
func (x *ExtrasValue) GetValue() isExtrasValue_Value
func (*ExtrasValue) ProtoMessage ¶
func (*ExtrasValue) ProtoMessage()
func (*ExtrasValue) ProtoReflect ¶
func (x *ExtrasValue) ProtoReflect() protoreflect.Message
func (*ExtrasValue) Reset ¶
func (x *ExtrasValue) Reset()
func (*ExtrasValue) String ¶
func (x *ExtrasValue) String() string
type ExtrasValue_Json ¶
type ExtrasValue_Json struct {
Json string `protobuf:"bytes,1,opt,name=json,proto3,oneof"`
}
type Info ¶
type Info struct {
Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
Author string `protobuf:"bytes,2,opt,name=author,proto3" json:"author,omitempty"`
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Website string `protobuf:"bytes,4,opt,name=website,proto3" json:"website,omitempty"`
Description string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty"`
License string `protobuf:"bytes,6,opt,name=license,proto3" json:"license,omitempty"`
ModulePath string `protobuf:"bytes,7,opt,name=module_path,json=modulePath,proto3" json:"module_path,omitempty"`
Capabilities *Capabilities `protobuf:"bytes,8,opt,name=capabilities,proto3" json:"capabilities,omitempty"`
// contains filtered or unexported fields
}
func (*Info) Descriptor
deprecated
func (*Info) GetCapabilities ¶
func (x *Info) GetCapabilities() *Capabilities
func (*Info) GetDescription ¶
func (*Info) GetLicense ¶
func (*Info) GetModulePath ¶
func (*Info) GetVersion ¶
func (*Info) GetWebsite ¶
func (*Info) ProtoMessage ¶
func (*Info) ProtoMessage()
func (*Info) ProtoReflect ¶
func (x *Info) ProtoReflect() protoreflect.Message
type InstanceUpdate ¶
type InstanceUpdate struct {
// Types that are valid to be assigned to Update:
//
// *InstanceUpdate_Ping
// *InstanceUpdate_Capable
// *InstanceUpdate_Message
// *InstanceUpdate_Storage
Update isInstanceUpdate_Update `protobuf_oneof:"update"`
// contains filtered or unexported fields
}
func (*InstanceUpdate) Descriptor
deprecated
func (*InstanceUpdate) Descriptor() ([]byte, []int)
Deprecated: Use InstanceUpdate.ProtoReflect.Descriptor instead.
func (*InstanceUpdate) GetCapable ¶
func (x *InstanceUpdate) GetCapable() Capability
func (*InstanceUpdate) GetMessage ¶
func (x *InstanceUpdate) GetMessage() *Message
func (*InstanceUpdate) GetPing ¶
func (x *InstanceUpdate) GetPing() *emptypb.Empty
func (*InstanceUpdate) GetStorage ¶
func (x *InstanceUpdate) GetStorage() []byte
func (*InstanceUpdate) GetUpdate ¶
func (x *InstanceUpdate) GetUpdate() isInstanceUpdate_Update
func (*InstanceUpdate) ProtoMessage ¶
func (*InstanceUpdate) ProtoMessage()
func (*InstanceUpdate) ProtoReflect ¶
func (x *InstanceUpdate) ProtoReflect() protoreflect.Message
func (*InstanceUpdate) Reset ¶
func (x *InstanceUpdate) Reset()
func (*InstanceUpdate) String ¶
func (x *InstanceUpdate) String() string
type InstanceUpdate_Capable ¶
type InstanceUpdate_Capable struct {
// enable support for a feature, must be one of the capabilities supported by the server
Capable Capability `protobuf:"varint,2,opt,name=capable,proto3,enum=Capability,oneof"`
}
type InstanceUpdate_Message ¶
type InstanceUpdate_Message struct {
// send a message to the user
Message *Message `protobuf:"bytes,3,opt,name=message,proto3,oneof"`
}
type InstanceUpdate_Ping ¶
type InstanceUpdate_Storage ¶
type InstanceUpdate_Storage struct {
// update persistent storage
Storage []byte `protobuf:"bytes,4,opt,name=storage,proto3,oneof"`
}
type Message ¶
type Message struct {
Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
Priority int32 `protobuf:"varint,3,opt,name=priority,proto3" json:"priority,omitempty"`
Extras map[string]*ExtrasValue `` /* 139-byte string literal not displayed */
// contains filtered or unexported fields
}
func (*Message) Descriptor
deprecated
func (*Message) GetExtras ¶
func (x *Message) GetExtras() map[string]*ExtrasValue
func (*Message) GetMessage ¶
func (*Message) GetPriority ¶
func (*Message) ProtoMessage ¶
func (*Message) ProtoMessage()
func (*Message) ProtoReflect ¶
func (x *Message) ProtoReflect() protoreflect.Message
type PluginClient ¶
type PluginClient interface {
// get the plugin info
GetPluginInfo(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*Info, error)
// graceful shutdown
GracefulShutdown(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*emptypb.Empty, error)
// run a user instance
RunUserInstance(ctx context.Context, in *UserInstanceRequest, opts ...grpc.CallOption) (grpc.ServerStreamingClient[InstanceUpdate], error)
}
PluginClient is the client API for Plugin service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
The base plugin service, which includes a plugin metadata endpoint, a per-user master switch, and a user instance stream.
func NewPluginClient ¶
func NewPluginClient(cc grpc.ClientConnInterface) PluginClient
type PluginServer ¶
type PluginServer interface {
// get the plugin info
GetPluginInfo(context.Context, *emptypb.Empty) (*Info, error)
// graceful shutdown
GracefulShutdown(context.Context, *emptypb.Empty) (*emptypb.Empty, error)
// run a user instance
RunUserInstance(*UserInstanceRequest, grpc.ServerStreamingServer[InstanceUpdate]) error
// contains filtered or unexported methods
}
PluginServer is the server API for Plugin service. All implementations must embed UnimplementedPluginServer for forward compatibility.
The base plugin service, which includes a plugin metadata endpoint, a per-user master switch, and a user instance stream.
type Plugin_RunUserInstanceClient ¶
type Plugin_RunUserInstanceClient = grpc.ServerStreamingClient[InstanceUpdate]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type Plugin_RunUserInstanceServer ¶
type Plugin_RunUserInstanceServer = grpc.ServerStreamingServer[InstanceUpdate]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ServerEvent ¶
type ServerEvent struct {
// Types that are valid to be assigned to Event:
//
// *ServerEvent_User
Event isServerEvent_Event `protobuf_oneof:"event"`
// contains filtered or unexported fields
}
func (*ServerEvent) Descriptor
deprecated
func (*ServerEvent) Descriptor() ([]byte, []int)
Deprecated: Use ServerEvent.ProtoReflect.Descriptor instead.
func (*ServerEvent) GetEvent ¶
func (x *ServerEvent) GetEvent() isServerEvent_Event
func (*ServerEvent) GetUser ¶
func (x *ServerEvent) GetUser() *UserContext
func (*ServerEvent) ProtoMessage ¶
func (*ServerEvent) ProtoMessage()
func (*ServerEvent) ProtoReflect ¶
func (x *ServerEvent) ProtoReflect() protoreflect.Message
func (*ServerEvent) Reset ¶
func (x *ServerEvent) Reset()
func (*ServerEvent) String ¶
func (x *ServerEvent) String() string
type ServerEventReceiverClient ¶
type ServerEventReceiverClient interface {
ServerEvents(ctx context.Context, opts ...grpc.CallOption) (grpc.ClientStreamingClient[ServerEvent, emptypb.Empty], error)
}
ServerEventReceiverClient is the client API for ServerEventReceiver service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
An optional RPC service that allows plugins to accept updates from the server.
func NewServerEventReceiverClient ¶
func NewServerEventReceiverClient(cc grpc.ClientConnInterface) ServerEventReceiverClient
type ServerEventReceiverServer ¶
type ServerEventReceiverServer interface {
ServerEvents(grpc.ClientStreamingServer[ServerEvent, emptypb.Empty]) error
// contains filtered or unexported methods
}
ServerEventReceiverServer is the server API for ServerEventReceiver service. All implementations must embed UnimplementedServerEventReceiverServer for forward compatibility.
An optional RPC service that allows plugins to accept updates from the server.
type ServerEventReceiver_ServerEventsClient ¶
type ServerEventReceiver_ServerEventsClient = grpc.ClientStreamingClient[ServerEvent, emptypb.Empty]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ServerEventReceiver_ServerEventsServer ¶
type ServerEventReceiver_ServerEventsServer = grpc.ClientStreamingServer[ServerEvent, emptypb.Empty]
This type alias is provided for backwards compatibility with existing code that references the prior non-generic stream type by name.
type ServerEvent_User ¶
type ServerEvent_User struct {
// A user has been created or updated.
User *UserContext `protobuf:"bytes,1,opt,name=user,proto3,oneof"`
}
type ServerInfo ¶
type ServerInfo struct {
Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
Commit string `protobuf:"bytes,2,opt,name=commit,proto3" json:"commit,omitempty"`
BuildDate string `protobuf:"bytes,3,opt,name=buildDate,proto3" json:"buildDate,omitempty"`
// supported capabilities of the gotify server itself
Capabilities []Capability `protobuf:"varint,4,rep,packed,name=capabilities,proto3,enum=Capability" json:"capabilities,omitempty"`
// contains filtered or unexported fields
}
func (*ServerInfo) Descriptor
deprecated
func (*ServerInfo) Descriptor() ([]byte, []int)
Deprecated: Use ServerInfo.ProtoReflect.Descriptor instead.
func (*ServerInfo) GetBuildDate ¶
func (x *ServerInfo) GetBuildDate() string
func (*ServerInfo) GetCapabilities ¶
func (x *ServerInfo) GetCapabilities() []Capability
func (*ServerInfo) GetCommit ¶
func (x *ServerInfo) GetCommit() string
func (*ServerInfo) GetVersion ¶
func (x *ServerInfo) GetVersion() string
func (*ServerInfo) ProtoMessage ¶
func (*ServerInfo) ProtoMessage()
func (*ServerInfo) ProtoReflect ¶
func (x *ServerInfo) ProtoReflect() protoreflect.Message
func (*ServerInfo) Reset ¶
func (x *ServerInfo) Reset()
func (*ServerInfo) String ¶
func (x *ServerInfo) String() string
type UnimplementedConfigurerServer ¶
type UnimplementedConfigurerServer struct{}
UnimplementedConfigurerServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedConfigurerServer) DefaultConfig ¶
func (UnimplementedConfigurerServer) DefaultConfig(context.Context, *DefaultConfigRequest) (*Config, error)
func (UnimplementedConfigurerServer) ValidateAndSetConfig ¶
func (UnimplementedConfigurerServer) ValidateAndSetConfig(context.Context, *ValidateAndSetConfigRequest) (*ValidateAndSetConfigResponse, error)
type UnimplementedDisplayerServer ¶
type UnimplementedDisplayerServer struct{}
UnimplementedDisplayerServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedDisplayerServer) Display ¶
func (UnimplementedDisplayerServer) Display(context.Context, *DisplayRequest) (*DisplayResponse, error)
type UnimplementedPluginServer ¶
type UnimplementedPluginServer struct{}
UnimplementedPluginServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedPluginServer) GetPluginInfo ¶
func (UnimplementedPluginServer) GracefulShutdown ¶
func (UnimplementedPluginServer) RunUserInstance ¶
func (UnimplementedPluginServer) RunUserInstance(*UserInstanceRequest, grpc.ServerStreamingServer[InstanceUpdate]) error
type UnimplementedServerEventReceiverServer ¶
type UnimplementedServerEventReceiverServer struct{}
UnimplementedServerEventReceiverServer must be embedded to have forward compatible implementations.
NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.
func (UnimplementedServerEventReceiverServer) ServerEvents ¶
func (UnimplementedServerEventReceiverServer) ServerEvents(grpc.ClientStreamingServer[ServerEvent, emptypb.Empty]) error
type UnsafeConfigurerServer ¶
type UnsafeConfigurerServer interface {
// contains filtered or unexported methods
}
UnsafeConfigurerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ConfigurerServer will result in compilation errors.
type UnsafeDisplayerServer ¶
type UnsafeDisplayerServer interface {
// contains filtered or unexported methods
}
UnsafeDisplayerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to DisplayerServer will result in compilation errors.
type UnsafePluginServer ¶
type UnsafePluginServer interface {
// contains filtered or unexported methods
}
UnsafePluginServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PluginServer will result in compilation errors.
type UnsafeServerEventReceiverServer ¶
type UnsafeServerEventReceiverServer interface {
// contains filtered or unexported methods
}
UnsafeServerEventReceiverServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ServerEventReceiverServer will result in compilation errors.
type UserContext ¶
type UserContext struct {
Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
Admin bool `protobuf:"varint,3,opt,name=admin,proto3" json:"admin,omitempty"`
// contains filtered or unexported fields
}
func (*UserContext) Descriptor
deprecated
func (*UserContext) Descriptor() ([]byte, []int)
Deprecated: Use UserContext.ProtoReflect.Descriptor instead.
func (*UserContext) GetAdmin ¶
func (x *UserContext) GetAdmin() bool
func (*UserContext) GetId ¶
func (x *UserContext) GetId() uint64
func (*UserContext) GetName ¶
func (x *UserContext) GetName() string
func (*UserContext) ProtoMessage ¶
func (*UserContext) ProtoMessage()
func (*UserContext) ProtoReflect ¶
func (x *UserContext) ProtoReflect() protoreflect.Message
func (*UserContext) Reset ¶
func (x *UserContext) Reset()
func (*UserContext) String ¶
func (x *UserContext) String() string
type UserInstanceRequest ¶
type UserInstanceRequest struct {
// the server info
ServerInfo *ServerInfo `protobuf:"bytes,1,opt,name=serverInfo,proto3" json:"serverInfo,omitempty"`
// the user context
User *UserContext `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"`
// the webhook base path
WebhookBasePath *string `protobuf:"bytes,3,opt,name=webhookBasePath,proto3,oneof" json:"webhookBasePath,omitempty"`
// the config
Config []byte `protobuf:"bytes,4,opt,name=config,proto3,oneof" json:"config,omitempty"`
// the storage
Storage []byte `protobuf:"bytes,5,opt,name=storage,proto3,oneof" json:"storage,omitempty"`
// contains filtered or unexported fields
}
func (*UserInstanceRequest) Descriptor
deprecated
func (*UserInstanceRequest) Descriptor() ([]byte, []int)
Deprecated: Use UserInstanceRequest.ProtoReflect.Descriptor instead.
func (*UserInstanceRequest) GetConfig ¶
func (x *UserInstanceRequest) GetConfig() []byte
func (*UserInstanceRequest) GetServerInfo ¶
func (x *UserInstanceRequest) GetServerInfo() *ServerInfo
func (*UserInstanceRequest) GetStorage ¶
func (x *UserInstanceRequest) GetStorage() []byte
func (*UserInstanceRequest) GetUser ¶
func (x *UserInstanceRequest) GetUser() *UserContext
func (*UserInstanceRequest) GetWebhookBasePath ¶
func (x *UserInstanceRequest) GetWebhookBasePath() string
func (*UserInstanceRequest) ProtoMessage ¶
func (*UserInstanceRequest) ProtoMessage()
func (*UserInstanceRequest) ProtoReflect ¶
func (x *UserInstanceRequest) ProtoReflect() protoreflect.Message
func (*UserInstanceRequest) Reset ¶
func (x *UserInstanceRequest) Reset()
func (*UserInstanceRequest) String ¶
func (x *UserInstanceRequest) String() string
type ValidateAndSetConfigRequest ¶
type ValidateAndSetConfigRequest struct {
// The user context the configuration belongs to.
User *UserContext `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
// The YAML configuration data.
Config *Config `protobuf:"bytes,2,opt,name=config,proto3" json:"config,omitempty"`
// contains filtered or unexported fields
}
func (*ValidateAndSetConfigRequest) Descriptor
deprecated
func (*ValidateAndSetConfigRequest) Descriptor() ([]byte, []int)
Deprecated: Use ValidateAndSetConfigRequest.ProtoReflect.Descriptor instead.
func (*ValidateAndSetConfigRequest) GetConfig ¶
func (x *ValidateAndSetConfigRequest) GetConfig() *Config
func (*ValidateAndSetConfigRequest) GetUser ¶
func (x *ValidateAndSetConfigRequest) GetUser() *UserContext
func (*ValidateAndSetConfigRequest) ProtoMessage ¶
func (*ValidateAndSetConfigRequest) ProtoMessage()
func (*ValidateAndSetConfigRequest) ProtoReflect ¶
func (x *ValidateAndSetConfigRequest) ProtoReflect() protoreflect.Message
func (*ValidateAndSetConfigRequest) Reset ¶
func (x *ValidateAndSetConfigRequest) Reset()
func (*ValidateAndSetConfigRequest) String ¶
func (x *ValidateAndSetConfigRequest) String() string
type ValidateAndSetConfigResponse ¶
type ValidateAndSetConfigResponse struct {
// The response to the request.
//
// Types that are valid to be assigned to Response:
//
// *ValidateAndSetConfigResponse_Success
// *ValidateAndSetConfigResponse_ValidationError
Response isValidateAndSetConfigResponse_Response `protobuf_oneof:"response"`
// contains filtered or unexported fields
}
func (*ValidateAndSetConfigResponse) Descriptor
deprecated
func (*ValidateAndSetConfigResponse) Descriptor() ([]byte, []int)
Deprecated: Use ValidateAndSetConfigResponse.ProtoReflect.Descriptor instead.
func (*ValidateAndSetConfigResponse) GetResponse ¶
func (x *ValidateAndSetConfigResponse) GetResponse() isValidateAndSetConfigResponse_Response
func (*ValidateAndSetConfigResponse) GetSuccess ¶
func (x *ValidateAndSetConfigResponse) GetSuccess() *emptypb.Empty
func (*ValidateAndSetConfigResponse) GetValidationError ¶
func (x *ValidateAndSetConfigResponse) GetValidationError() *Error
func (*ValidateAndSetConfigResponse) ProtoMessage ¶
func (*ValidateAndSetConfigResponse) ProtoMessage()
func (*ValidateAndSetConfigResponse) ProtoReflect ¶
func (x *ValidateAndSetConfigResponse) ProtoReflect() protoreflect.Message
func (*ValidateAndSetConfigResponse) Reset ¶
func (x *ValidateAndSetConfigResponse) Reset()
func (*ValidateAndSetConfigResponse) String ¶
func (x *ValidateAndSetConfigResponse) String() string
type ValidateAndSetConfigResponse_ValidationError ¶
type ValidateAndSetConfigResponse_ValidationError struct {
// The validation error response.
ValidationError *Error `protobuf:"bytes,2,opt,name=validation_error,json=validationError,proto3,oneof"`
}