Documentation
¶
Overview ¶
Package imap_concentrator is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Variables
- func RegisterImapConcentratorHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterImapConcentratorHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ImapConcentratorClient) error
- func RegisterImapConcentratorHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterImapConcentratorHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ImapConcentratorServer) error
- func RegisterImapConcentratorServer(s grpc.ServiceRegistrar, srv ImapConcentratorServer)
- type Ack
- type AssignUniqueClientIDRequest
- type AssignUniqueClientIDResponse
- func (*AssignUniqueClientIDResponse) Descriptor() ([]byte, []int)deprecated
- func (x *AssignUniqueClientIDResponse) GetClientID() int64
- func (*AssignUniqueClientIDResponse) ProtoMessage()
- func (x *AssignUniqueClientIDResponse) ProtoReflect() protoreflect.Message
- func (x *AssignUniqueClientIDResponse) Reset()
- func (x *AssignUniqueClientIDResponse) String() string
- type DeleteMailboxV1Request
- func (*DeleteMailboxV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteMailboxV1Request) GetChatID() int64
- func (x *DeleteMailboxV1Request) GetMailboxID() int64
- func (*DeleteMailboxV1Request) ProtoMessage()
- func (x *DeleteMailboxV1Request) ProtoReflect() protoreflect.Message
- func (x *DeleteMailboxV1Request) Reset()
- func (x *DeleteMailboxV1Request) String() string
- type GetMailboxV1Request
- func (*GetMailboxV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *GetMailboxV1Request) GetChatID() int64
- func (x *GetMailboxV1Request) GetMailboxID() int64
- func (*GetMailboxV1Request) ProtoMessage()
- func (x *GetMailboxV1Request) ProtoReflect() protoreflect.Message
- func (x *GetMailboxV1Request) Reset()
- func (x *GetMailboxV1Request) String() string
- type GetMailboxV1Response
- func (*GetMailboxV1Response) Descriptor() ([]byte, []int)deprecated
- func (x *GetMailboxV1Response) GetChatID() int64
- func (x *GetMailboxV1Response) GetMailbox() *MailboxV1
- func (*GetMailboxV1Response) ProtoMessage()
- func (x *GetMailboxV1Response) ProtoReflect() protoreflect.Message
- func (x *GetMailboxV1Response) Reset()
- func (x *GetMailboxV1Response) String() string
- type ImapConcentratorClient
- type ImapConcentratorServer
- type ImapConcentrator_SubscribeToAllNotificationsV1Client
- type ImapConcentrator_SubscribeToAllNotificationsV1Server
- type ImapConcentrator_SubscribeToChatNotificationsV1Client
- type ImapConcentrator_SubscribeToChatNotificationsV1Server
- type InsertChatV1Request
- func (*InsertChatV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *InsertChatV1Request) GetChatID() int64
- func (*InsertChatV1Request) ProtoMessage()
- func (x *InsertChatV1Request) ProtoReflect() protoreflect.Message
- func (x *InsertChatV1Request) Reset()
- func (x *InsertChatV1Request) String() string
- type InsertMailboxV1Request
- func (*InsertMailboxV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *InsertMailboxV1Request) GetChatID() int64
- func (x *InsertMailboxV1Request) GetMailbox() *MailboxV1
- func (*InsertMailboxV1Request) ProtoMessage()
- func (x *InsertMailboxV1Request) ProtoReflect() protoreflect.Message
- func (x *InsertMailboxV1Request) Reset()
- func (x *InsertMailboxV1Request) String() string
- type ListMailboxesV1Request
- func (*ListMailboxesV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *ListMailboxesV1Request) GetChatID() int64
- func (*ListMailboxesV1Request) ProtoMessage()
- func (x *ListMailboxesV1Request) ProtoReflect() protoreflect.Message
- func (x *ListMailboxesV1Request) Reset()
- func (x *ListMailboxesV1Request) String() string
- type ListMailboxesV1Response
- func (*ListMailboxesV1Response) Descriptor() ([]byte, []int)deprecated
- func (x *ListMailboxesV1Response) GetMailboxes() []*MailboxV1
- func (*ListMailboxesV1Response) ProtoMessage()
- func (x *ListMailboxesV1Response) ProtoReflect() protoreflect.Message
- func (x *ListMailboxesV1Response) Reset()
- func (x *ListMailboxesV1Response) String() string
- type MailboxV1
- func (*MailboxV1) Descriptor() ([]byte, []int)deprecated
- func (x *MailboxV1) GetHost() string
- func (x *MailboxV1) GetMailbox() string
- func (x *MailboxV1) GetMailboxID() int64
- func (x *MailboxV1) GetPassword() string
- func (x *MailboxV1) GetPort() int32
- func (x *MailboxV1) GetUsername() string
- func (*MailboxV1) ProtoMessage()
- func (x *MailboxV1) ProtoReflect() protoreflect.Message
- func (x *MailboxV1) Reset()
- func (x *MailboxV1) String() string
- type NotificationV1
- func (*NotificationV1) Descriptor() ([]byte, []int)deprecated
- func (x *NotificationV1) GetBody() string
- func (x *NotificationV1) GetChatID() int64
- func (x *NotificationV1) GetEmail() string
- func (x *NotificationV1) GetHost() string
- func (x *NotificationV1) GetMailbox() string
- func (x *NotificationV1) GetPort() int32
- func (x *NotificationV1) GetSender() string
- func (x *NotificationV1) GetTimestamp() *timestamppb.Timestamp
- func (x *NotificationV1) GetTitle() string
- func (*NotificationV1) ProtoMessage()
- func (x *NotificationV1) ProtoReflect() protoreflect.Message
- func (x *NotificationV1) Reset()
- func (x *NotificationV1) String() string
- type PollV1Request
- type SubscribeToAllNotificationsV1Request
- func (*SubscribeToAllNotificationsV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *SubscribeToAllNotificationsV1Request) GetClientID() int64
- func (x *SubscribeToAllNotificationsV1Request) GetKey() string
- func (*SubscribeToAllNotificationsV1Request) ProtoMessage()
- func (x *SubscribeToAllNotificationsV1Request) ProtoReflect() protoreflect.Message
- func (x *SubscribeToAllNotificationsV1Request) Reset()
- func (x *SubscribeToAllNotificationsV1Request) String() string
- type SubscribeToChatNotificationsV1Request
- func (*SubscribeToChatNotificationsV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *SubscribeToChatNotificationsV1Request) GetChatID() int64
- func (x *SubscribeToChatNotificationsV1Request) GetClientID() int64
- func (*SubscribeToChatNotificationsV1Request) ProtoMessage()
- func (x *SubscribeToChatNotificationsV1Request) ProtoReflect() protoreflect.Message
- func (x *SubscribeToChatNotificationsV1Request) Reset()
- func (x *SubscribeToChatNotificationsV1Request) String() string
- type UnimplementedImapConcentratorServer
- func (UnimplementedImapConcentratorServer) AssignUniqueClientID(context.Context, *AssignUniqueClientIDRequest) (*AssignUniqueClientIDResponse, error)
- func (UnimplementedImapConcentratorServer) DeleteMailboxV1(context.Context, *DeleteMailboxV1Request) (*Ack, error)
- func (UnimplementedImapConcentratorServer) GetMailboxV1(context.Context, *GetMailboxV1Request) (*GetMailboxV1Response, error)
- func (UnimplementedImapConcentratorServer) InsertChatV1(context.Context, *InsertChatV1Request) (*Ack, error)
- func (UnimplementedImapConcentratorServer) InsertMailboxV1(context.Context, *InsertMailboxV1Request) (*Ack, error)
- func (UnimplementedImapConcentratorServer) ListMailboxesV1(context.Context, *ListMailboxesV1Request) (*ListMailboxesV1Response, error)
- func (UnimplementedImapConcentratorServer) PollV1(context.Context, *PollV1Request) (*Ack, error)
- func (UnimplementedImapConcentratorServer) SubscribeToAllNotificationsV1(*SubscribeToAllNotificationsV1Request, ...) error
- func (UnimplementedImapConcentratorServer) SubscribeToChatNotificationsV1(*SubscribeToChatNotificationsV1Request, ...) error
- func (UnimplementedImapConcentratorServer) UnsubscribeFromNotificationsV1(context.Context, *UnsubscribeFromNotificationsV1Request) (*Ack, error)
- func (UnimplementedImapConcentratorServer) UpdateMailboxV1(context.Context, *UpdateMailboxV1Request) (*Ack, error)
- type UnsafeImapConcentratorServer
- type UnsubscribeFromNotificationsV1Request
- func (*UnsubscribeFromNotificationsV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *UnsubscribeFromNotificationsV1Request) GetClientID() int64
- func (*UnsubscribeFromNotificationsV1Request) ProtoMessage()
- func (x *UnsubscribeFromNotificationsV1Request) ProtoReflect() protoreflect.Message
- func (x *UnsubscribeFromNotificationsV1Request) Reset()
- func (x *UnsubscribeFromNotificationsV1Request) String() string
- type UpdateMailboxV1Request
- func (*UpdateMailboxV1Request) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateMailboxV1Request) GetChatID() int64
- func (x *UpdateMailboxV1Request) GetMailbox() *MailboxV1
- func (*UpdateMailboxV1Request) ProtoMessage()
- func (x *UpdateMailboxV1Request) ProtoReflect() protoreflect.Message
- func (x *UpdateMailboxV1Request) Reset()
- func (x *UpdateMailboxV1Request) String() string
Constants ¶
This section is empty.
Variables ¶
var File_imap_concentrator_v1_imap_concentrator_proto protoreflect.FileDescriptor
var ImapConcentrator_ServiceDesc = grpc.ServiceDesc{ ServiceName: "aveplen.imap_concentrator.v1.ImapConcentrator", HandlerType: (*ImapConcentratorServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "AssignUniqueClientID", Handler: _ImapConcentrator_AssignUniqueClientID_Handler, }, { MethodName: "UnsubscribeFromNotificationsV1", Handler: _ImapConcentrator_UnsubscribeFromNotificationsV1_Handler, }, { MethodName: "InsertMailboxV1", Handler: _ImapConcentrator_InsertMailboxV1_Handler, }, { MethodName: "InsertChatV1", Handler: _ImapConcentrator_InsertChatV1_Handler, }, { MethodName: "PollV1", Handler: _ImapConcentrator_PollV1_Handler, }, { MethodName: "ListMailboxesV1", Handler: _ImapConcentrator_ListMailboxesV1_Handler, }, { MethodName: "GetMailboxV1", Handler: _ImapConcentrator_GetMailboxV1_Handler, }, { MethodName: "UpdateMailboxV1", Handler: _ImapConcentrator_UpdateMailboxV1_Handler, }, { MethodName: "DeleteMailboxV1", Handler: _ImapConcentrator_DeleteMailboxV1_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "SubscribeToAllNotificationsV1", Handler: _ImapConcentrator_SubscribeToAllNotificationsV1_Handler, ServerStreams: true, }, { StreamName: "SubscribeToChatNotificationsV1", Handler: _ImapConcentrator_SubscribeToChatNotificationsV1_Handler, ServerStreams: true, }, }, Metadata: "imap_concentrator/v1/imap_concentrator.proto", }
ImapConcentrator_ServiceDesc is the grpc.ServiceDesc for ImapConcentrator service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterImapConcentratorHandler ¶
func RegisterImapConcentratorHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterImapConcentratorHandler registers the http handlers for service ImapConcentrator to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterImapConcentratorHandlerClient ¶
func RegisterImapConcentratorHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ImapConcentratorClient) error
RegisterImapConcentratorHandlerClient registers the http handlers for service ImapConcentrator to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ImapConcentratorClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ImapConcentratorClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ImapConcentratorClient" to call the correct interceptors.
func RegisterImapConcentratorHandlerFromEndpoint ¶
func RegisterImapConcentratorHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterImapConcentratorHandlerFromEndpoint is same as RegisterImapConcentratorHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterImapConcentratorHandlerServer ¶
func RegisterImapConcentratorHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ImapConcentratorServer) error
RegisterImapConcentratorHandlerServer registers the http handlers for service ImapConcentrator to "mux". UnaryRPC :call ImapConcentratorServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterImapConcentratorHandlerFromEndpoint instead.
func RegisterImapConcentratorServer ¶
func RegisterImapConcentratorServer(s grpc.ServiceRegistrar, srv ImapConcentratorServer)
Types ¶
type Ack ¶
type Ack struct {
// contains filtered or unexported fields
}
Model for acknowledge.
func (*Ack) Descriptor
deprecated
func (*Ack) ProtoMessage ¶
func (*Ack) ProtoMessage()
func (*Ack) ProtoReflect ¶
func (x *Ack) ProtoReflect() protoreflect.Message
type AssignUniqueClientIDRequest ¶
type AssignUniqueClientIDRequest struct {
// contains filtered or unexported fields
}
Every client should subscribe to stream with unique client id. To make sure that all id-s are unique, they are generated by server. Synchronous api endpoints do not require client id.
func (*AssignUniqueClientIDRequest) Descriptor
deprecated
func (*AssignUniqueClientIDRequest) Descriptor() ([]byte, []int)
Deprecated: Use AssignUniqueClientIDRequest.ProtoReflect.Descriptor instead.
func (*AssignUniqueClientIDRequest) ProtoMessage ¶
func (*AssignUniqueClientIDRequest) ProtoMessage()
func (*AssignUniqueClientIDRequest) ProtoReflect ¶
func (x *AssignUniqueClientIDRequest) ProtoReflect() protoreflect.Message
func (*AssignUniqueClientIDRequest) Reset ¶
func (x *AssignUniqueClientIDRequest) Reset()
func (*AssignUniqueClientIDRequest) String ¶
func (x *AssignUniqueClientIDRequest) String() string
type AssignUniqueClientIDResponse ¶
type AssignUniqueClientIDResponse struct { ClientID int64 `protobuf:"varint,1,opt,name=clientID,proto3" json:"clientID,omitempty"` // contains filtered or unexported fields }
func (*AssignUniqueClientIDResponse) Descriptor
deprecated
func (*AssignUniqueClientIDResponse) Descriptor() ([]byte, []int)
Deprecated: Use AssignUniqueClientIDResponse.ProtoReflect.Descriptor instead.
func (*AssignUniqueClientIDResponse) GetClientID ¶
func (x *AssignUniqueClientIDResponse) GetClientID() int64
func (*AssignUniqueClientIDResponse) ProtoMessage ¶
func (*AssignUniqueClientIDResponse) ProtoMessage()
func (*AssignUniqueClientIDResponse) ProtoReflect ¶
func (x *AssignUniqueClientIDResponse) ProtoReflect() protoreflect.Message
func (*AssignUniqueClientIDResponse) Reset ¶
func (x *AssignUniqueClientIDResponse) Reset()
func (*AssignUniqueClientIDResponse) String ¶
func (x *AssignUniqueClientIDResponse) String() string
type DeleteMailboxV1Request ¶
type DeleteMailboxV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` MailboxID int64 `protobuf:"varint,2,opt,name=mailboxID,proto3" json:"mailboxID,omitempty"` // contains filtered or unexported fields }
Delete to remove mailbox with given database id from tracking list.
func (*DeleteMailboxV1Request) Descriptor
deprecated
func (*DeleteMailboxV1Request) Descriptor() ([]byte, []int)
Deprecated: Use DeleteMailboxV1Request.ProtoReflect.Descriptor instead.
func (*DeleteMailboxV1Request) GetChatID ¶
func (x *DeleteMailboxV1Request) GetChatID() int64
func (*DeleteMailboxV1Request) GetMailboxID ¶
func (x *DeleteMailboxV1Request) GetMailboxID() int64
func (*DeleteMailboxV1Request) ProtoMessage ¶
func (*DeleteMailboxV1Request) ProtoMessage()
func (*DeleteMailboxV1Request) ProtoReflect ¶
func (x *DeleteMailboxV1Request) ProtoReflect() protoreflect.Message
func (*DeleteMailboxV1Request) Reset ¶
func (x *DeleteMailboxV1Request) Reset()
func (*DeleteMailboxV1Request) String ¶
func (x *DeleteMailboxV1Request) String() string
type GetMailboxV1Request ¶
type GetMailboxV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` MailboxID int64 `protobuf:"varint,2,opt,name=mailboxID,proto3" json:"mailboxID,omitempty"` // contains filtered or unexported fields }
Get info about particular mailbox by id
func (*GetMailboxV1Request) Descriptor
deprecated
func (*GetMailboxV1Request) Descriptor() ([]byte, []int)
Deprecated: Use GetMailboxV1Request.ProtoReflect.Descriptor instead.
func (*GetMailboxV1Request) GetChatID ¶
func (x *GetMailboxV1Request) GetChatID() int64
func (*GetMailboxV1Request) GetMailboxID ¶
func (x *GetMailboxV1Request) GetMailboxID() int64
func (*GetMailboxV1Request) ProtoMessage ¶
func (*GetMailboxV1Request) ProtoMessage()
func (*GetMailboxV1Request) ProtoReflect ¶
func (x *GetMailboxV1Request) ProtoReflect() protoreflect.Message
func (*GetMailboxV1Request) Reset ¶
func (x *GetMailboxV1Request) Reset()
func (*GetMailboxV1Request) String ¶
func (x *GetMailboxV1Request) String() string
type GetMailboxV1Response ¶
type GetMailboxV1Response struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` Mailbox *MailboxV1 `protobuf:"bytes,2,opt,name=mailbox,proto3" json:"mailbox,omitempty"` // contains filtered or unexported fields }
func (*GetMailboxV1Response) Descriptor
deprecated
func (*GetMailboxV1Response) Descriptor() ([]byte, []int)
Deprecated: Use GetMailboxV1Response.ProtoReflect.Descriptor instead.
func (*GetMailboxV1Response) GetChatID ¶
func (x *GetMailboxV1Response) GetChatID() int64
func (*GetMailboxV1Response) GetMailbox ¶
func (x *GetMailboxV1Response) GetMailbox() *MailboxV1
func (*GetMailboxV1Response) ProtoMessage ¶
func (*GetMailboxV1Response) ProtoMessage()
func (*GetMailboxV1Response) ProtoReflect ¶
func (x *GetMailboxV1Response) ProtoReflect() protoreflect.Message
func (*GetMailboxV1Response) Reset ¶
func (x *GetMailboxV1Response) Reset()
func (*GetMailboxV1Response) String ¶
func (x *GetMailboxV1Response) String() string
type ImapConcentratorClient ¶
type ImapConcentratorClient interface { AssignUniqueClientID(ctx context.Context, in *AssignUniqueClientIDRequest, opts ...grpc.CallOption) (*AssignUniqueClientIDResponse, error) SubscribeToAllNotificationsV1(ctx context.Context, in *SubscribeToAllNotificationsV1Request, opts ...grpc.CallOption) (ImapConcentrator_SubscribeToAllNotificationsV1Client, error) SubscribeToChatNotificationsV1(ctx context.Context, in *SubscribeToChatNotificationsV1Request, opts ...grpc.CallOption) (ImapConcentrator_SubscribeToChatNotificationsV1Client, error) UnsubscribeFromNotificationsV1(ctx context.Context, in *UnsubscribeFromNotificationsV1Request, opts ...grpc.CallOption) (*Ack, error) InsertMailboxV1(ctx context.Context, in *InsertMailboxV1Request, opts ...grpc.CallOption) (*Ack, error) // This rpc should not have gateway endpoint. It is used to authenticate clients. InsertChatV1(ctx context.Context, in *InsertChatV1Request, opts ...grpc.CallOption) (*Ack, error) PollV1(ctx context.Context, in *PollV1Request, opts ...grpc.CallOption) (*Ack, error) ListMailboxesV1(ctx context.Context, in *ListMailboxesV1Request, opts ...grpc.CallOption) (*ListMailboxesV1Response, error) GetMailboxV1(ctx context.Context, in *GetMailboxV1Request, opts ...grpc.CallOption) (*GetMailboxV1Response, error) UpdateMailboxV1(ctx context.Context, in *UpdateMailboxV1Request, opts ...grpc.CallOption) (*Ack, error) DeleteMailboxV1(ctx context.Context, in *DeleteMailboxV1Request, opts ...grpc.CallOption) (*Ack, error) }
ImapConcentratorClient is the client API for ImapConcentrator 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.
func NewImapConcentratorClient ¶
func NewImapConcentratorClient(cc grpc.ClientConnInterface) ImapConcentratorClient
type ImapConcentratorServer ¶
type ImapConcentratorServer interface { AssignUniqueClientID(context.Context, *AssignUniqueClientIDRequest) (*AssignUniqueClientIDResponse, error) SubscribeToAllNotificationsV1(*SubscribeToAllNotificationsV1Request, ImapConcentrator_SubscribeToAllNotificationsV1Server) error SubscribeToChatNotificationsV1(*SubscribeToChatNotificationsV1Request, ImapConcentrator_SubscribeToChatNotificationsV1Server) error UnsubscribeFromNotificationsV1(context.Context, *UnsubscribeFromNotificationsV1Request) (*Ack, error) InsertMailboxV1(context.Context, *InsertMailboxV1Request) (*Ack, error) // This rpc should not have gateway endpoint. It is used to authenticate clients. InsertChatV1(context.Context, *InsertChatV1Request) (*Ack, error) PollV1(context.Context, *PollV1Request) (*Ack, error) ListMailboxesV1(context.Context, *ListMailboxesV1Request) (*ListMailboxesV1Response, error) GetMailboxV1(context.Context, *GetMailboxV1Request) (*GetMailboxV1Response, error) UpdateMailboxV1(context.Context, *UpdateMailboxV1Request) (*Ack, error) DeleteMailboxV1(context.Context, *DeleteMailboxV1Request) (*Ack, error) // contains filtered or unexported methods }
ImapConcentratorServer is the server API for ImapConcentrator service. All implementations must embed UnimplementedImapConcentratorServer for forward compatibility
type ImapConcentrator_SubscribeToAllNotificationsV1Client ¶
type ImapConcentrator_SubscribeToAllNotificationsV1Client interface { Recv() (*NotificationV1, error) grpc.ClientStream }
type ImapConcentrator_SubscribeToAllNotificationsV1Server ¶
type ImapConcentrator_SubscribeToAllNotificationsV1Server interface { Send(*NotificationV1) error grpc.ServerStream }
type ImapConcentrator_SubscribeToChatNotificationsV1Client ¶
type ImapConcentrator_SubscribeToChatNotificationsV1Client interface { Recv() (*NotificationV1, error) grpc.ClientStream }
type ImapConcentrator_SubscribeToChatNotificationsV1Server ¶
type ImapConcentrator_SubscribeToChatNotificationsV1Server interface { Send(*NotificationV1) error grpc.ServerStream }
type InsertChatV1Request ¶
type InsertChatV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` // contains filtered or unexported fields }
Request to start conversation via saving unique client id to database for future mailbox assignment.
func (*InsertChatV1Request) Descriptor
deprecated
func (*InsertChatV1Request) Descriptor() ([]byte, []int)
Deprecated: Use InsertChatV1Request.ProtoReflect.Descriptor instead.
func (*InsertChatV1Request) GetChatID ¶
func (x *InsertChatV1Request) GetChatID() int64
func (*InsertChatV1Request) ProtoMessage ¶
func (*InsertChatV1Request) ProtoMessage()
func (*InsertChatV1Request) ProtoReflect ¶
func (x *InsertChatV1Request) ProtoReflect() protoreflect.Message
func (*InsertChatV1Request) Reset ¶
func (x *InsertChatV1Request) Reset()
func (*InsertChatV1Request) String ¶
func (x *InsertChatV1Request) String() string
type InsertMailboxV1Request ¶
type InsertMailboxV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` Mailbox *MailboxV1 `protobuf:"bytes,2,opt,name=mailbox,proto3" json:"mailbox,omitempty"` // contains filtered or unexported fields }
Request to insert new mailbox into tracking list and assign it to chat id.
func (*InsertMailboxV1Request) Descriptor
deprecated
func (*InsertMailboxV1Request) Descriptor() ([]byte, []int)
Deprecated: Use InsertMailboxV1Request.ProtoReflect.Descriptor instead.
func (*InsertMailboxV1Request) GetChatID ¶
func (x *InsertMailboxV1Request) GetChatID() int64
func (*InsertMailboxV1Request) GetMailbox ¶
func (x *InsertMailboxV1Request) GetMailbox() *MailboxV1
func (*InsertMailboxV1Request) ProtoMessage ¶
func (*InsertMailboxV1Request) ProtoMessage()
func (*InsertMailboxV1Request) ProtoReflect ¶
func (x *InsertMailboxV1Request) ProtoReflect() protoreflect.Message
func (*InsertMailboxV1Request) Reset ¶
func (x *InsertMailboxV1Request) Reset()
func (*InsertMailboxV1Request) String ¶
func (x *InsertMailboxV1Request) String() string
type ListMailboxesV1Request ¶
type ListMailboxesV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` // contains filtered or unexported fields }
Get a list of mailboxes assigned to given chat id.
func (*ListMailboxesV1Request) Descriptor
deprecated
func (*ListMailboxesV1Request) Descriptor() ([]byte, []int)
Deprecated: Use ListMailboxesV1Request.ProtoReflect.Descriptor instead.
func (*ListMailboxesV1Request) GetChatID ¶
func (x *ListMailboxesV1Request) GetChatID() int64
func (*ListMailboxesV1Request) ProtoMessage ¶
func (*ListMailboxesV1Request) ProtoMessage()
func (*ListMailboxesV1Request) ProtoReflect ¶
func (x *ListMailboxesV1Request) ProtoReflect() protoreflect.Message
func (*ListMailboxesV1Request) Reset ¶
func (x *ListMailboxesV1Request) Reset()
func (*ListMailboxesV1Request) String ¶
func (x *ListMailboxesV1Request) String() string
type ListMailboxesV1Response ¶
type ListMailboxesV1Response struct { Mailboxes []*MailboxV1 `protobuf:"bytes,1,rep,name=mailboxes,proto3" json:"mailboxes,omitempty"` // contains filtered or unexported fields }
List of mailboxes. Includes database id's for possible removal.
func (*ListMailboxesV1Response) Descriptor
deprecated
func (*ListMailboxesV1Response) Descriptor() ([]byte, []int)
Deprecated: Use ListMailboxesV1Response.ProtoReflect.Descriptor instead.
func (*ListMailboxesV1Response) GetMailboxes ¶
func (x *ListMailboxesV1Response) GetMailboxes() []*MailboxV1
func (*ListMailboxesV1Response) ProtoMessage ¶
func (*ListMailboxesV1Response) ProtoMessage()
func (*ListMailboxesV1Response) ProtoReflect ¶
func (x *ListMailboxesV1Response) ProtoReflect() protoreflect.Message
func (*ListMailboxesV1Response) Reset ¶
func (x *ListMailboxesV1Response) Reset()
func (*ListMailboxesV1Response) String ¶
func (x *ListMailboxesV1Response) String() string
type MailboxV1 ¶
type MailboxV1 struct { MailboxID int64 `protobuf:"varint,1,opt,name=mailboxID,proto3" json:"mailboxID,omitempty"` Host string `protobuf:"bytes,2,opt,name=host,proto3" json:"host,omitempty"` Port int32 `protobuf:"varint,3,opt,name=port,proto3" json:"port,omitempty"` Mailbox string `protobuf:"bytes,4,opt,name=mailbox,proto3" json:"mailbox,omitempty"` Username string `protobuf:"bytes,5,opt,name=username,proto3" json:"username,omitempty"` Password string `protobuf:"bytes,6,opt,name=password,proto3" json:"password,omitempty"` // contains filtered or unexported fields }
Model for mailbox version 1.
func (*MailboxV1) Descriptor
deprecated
func (*MailboxV1) GetMailbox ¶
func (*MailboxV1) GetMailboxID ¶
func (*MailboxV1) GetPassword ¶
func (*MailboxV1) GetUsername ¶
func (*MailboxV1) ProtoMessage ¶
func (*MailboxV1) ProtoMessage()
func (*MailboxV1) ProtoReflect ¶
func (x *MailboxV1) ProtoReflect() protoreflect.Message
type NotificationV1 ¶
type NotificationV1 struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` Sender string `protobuf:"bytes,2,opt,name=sender,proto3" json:"sender,omitempty"` Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"` Host string `protobuf:"bytes,4,opt,name=host,proto3" json:"host,omitempty"` Port int32 `protobuf:"varint,5,opt,name=port,proto3" json:"port,omitempty"` Mailbox string `protobuf:"bytes,6,opt,name=mailbox,proto3" json:"mailbox,omitempty"` Title string `protobuf:"bytes,7,opt,name=title,proto3" json:"title,omitempty"` Body string `protobuf:"bytes,8,opt,name=body,proto3" json:"body,omitempty"` Timestamp *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // contains filtered or unexported fields }
Model for notification version 1.
func (*NotificationV1) Descriptor
deprecated
func (*NotificationV1) Descriptor() ([]byte, []int)
Deprecated: Use NotificationV1.ProtoReflect.Descriptor instead.
func (*NotificationV1) GetBody ¶
func (x *NotificationV1) GetBody() string
func (*NotificationV1) GetChatID ¶
func (x *NotificationV1) GetChatID() int64
func (*NotificationV1) GetEmail ¶
func (x *NotificationV1) GetEmail() string
func (*NotificationV1) GetHost ¶
func (x *NotificationV1) GetHost() string
func (*NotificationV1) GetMailbox ¶
func (x *NotificationV1) GetMailbox() string
func (*NotificationV1) GetPort ¶
func (x *NotificationV1) GetPort() int32
func (*NotificationV1) GetSender ¶
func (x *NotificationV1) GetSender() string
func (*NotificationV1) GetTimestamp ¶
func (x *NotificationV1) GetTimestamp() *timestamppb.Timestamp
func (*NotificationV1) GetTitle ¶
func (x *NotificationV1) GetTitle() string
func (*NotificationV1) ProtoMessage ¶
func (*NotificationV1) ProtoMessage()
func (*NotificationV1) ProtoReflect ¶
func (x *NotificationV1) ProtoReflect() protoreflect.Message
func (*NotificationV1) Reset ¶
func (x *NotificationV1) Reset()
func (*NotificationV1) String ¶
func (x *NotificationV1) String() string
type PollV1Request ¶
type PollV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` // contains filtered or unexported fields }
Request to poll mailboxes assigned to given chat id asap. (not waiting for cron)
func (*PollV1Request) Descriptor
deprecated
func (*PollV1Request) Descriptor() ([]byte, []int)
Deprecated: Use PollV1Request.ProtoReflect.Descriptor instead.
func (*PollV1Request) GetChatID ¶
func (x *PollV1Request) GetChatID() int64
func (*PollV1Request) ProtoMessage ¶
func (*PollV1Request) ProtoMessage()
func (*PollV1Request) ProtoReflect ¶
func (x *PollV1Request) ProtoReflect() protoreflect.Message
func (*PollV1Request) Reset ¶
func (x *PollV1Request) Reset()
func (*PollV1Request) String ¶
func (x *PollV1Request) String() string
type SubscribeToAllNotificationsV1Request ¶
type SubscribeToAllNotificationsV1Request struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` ClientID int64 `protobuf:"varint,2,opt,name=clientID,proto3" json:"clientID,omitempty"` // contains filtered or unexported fields }
Subscribe to notifications from all tracked imap mailboxes. (to be used by bot)
func (*SubscribeToAllNotificationsV1Request) Descriptor
deprecated
func (*SubscribeToAllNotificationsV1Request) Descriptor() ([]byte, []int)
Deprecated: Use SubscribeToAllNotificationsV1Request.ProtoReflect.Descriptor instead.
func (*SubscribeToAllNotificationsV1Request) GetClientID ¶
func (x *SubscribeToAllNotificationsV1Request) GetClientID() int64
func (*SubscribeToAllNotificationsV1Request) GetKey ¶
func (x *SubscribeToAllNotificationsV1Request) GetKey() string
func (*SubscribeToAllNotificationsV1Request) ProtoMessage ¶
func (*SubscribeToAllNotificationsV1Request) ProtoMessage()
func (*SubscribeToAllNotificationsV1Request) ProtoReflect ¶
func (x *SubscribeToAllNotificationsV1Request) ProtoReflect() protoreflect.Message
func (*SubscribeToAllNotificationsV1Request) Reset ¶
func (x *SubscribeToAllNotificationsV1Request) Reset()
func (*SubscribeToAllNotificationsV1Request) String ¶
func (x *SubscribeToAllNotificationsV1Request) String() string
type SubscribeToChatNotificationsV1Request ¶
type SubscribeToChatNotificationsV1Request struct { ClientID int64 `protobuf:"varint,1,opt,name=clientID,proto3" json:"clientID,omitempty"` ChatID int64 `protobuf:"varint,2,opt,name=chatID,proto3" json:"chatID,omitempty"` // contains filtered or unexported fields }
Subscribe to notifications from mailboxes assigned to unique telegram chat id. Tg chat id serves the purpose of api access token. You cannot access this endpoint unless you initialized profile via bot's /start command. (to be used by gateway)
func (*SubscribeToChatNotificationsV1Request) Descriptor
deprecated
func (*SubscribeToChatNotificationsV1Request) Descriptor() ([]byte, []int)
Deprecated: Use SubscribeToChatNotificationsV1Request.ProtoReflect.Descriptor instead.
func (*SubscribeToChatNotificationsV1Request) GetChatID ¶
func (x *SubscribeToChatNotificationsV1Request) GetChatID() int64
func (*SubscribeToChatNotificationsV1Request) GetClientID ¶
func (x *SubscribeToChatNotificationsV1Request) GetClientID() int64
func (*SubscribeToChatNotificationsV1Request) ProtoMessage ¶
func (*SubscribeToChatNotificationsV1Request) ProtoMessage()
func (*SubscribeToChatNotificationsV1Request) ProtoReflect ¶
func (x *SubscribeToChatNotificationsV1Request) ProtoReflect() protoreflect.Message
func (*SubscribeToChatNotificationsV1Request) Reset ¶
func (x *SubscribeToChatNotificationsV1Request) Reset()
func (*SubscribeToChatNotificationsV1Request) String ¶
func (x *SubscribeToChatNotificationsV1Request) String() string
type UnimplementedImapConcentratorServer ¶
type UnimplementedImapConcentratorServer struct { }
UnimplementedImapConcentratorServer must be embedded to have forward compatible implementations.
func (UnimplementedImapConcentratorServer) AssignUniqueClientID ¶
func (UnimplementedImapConcentratorServer) AssignUniqueClientID(context.Context, *AssignUniqueClientIDRequest) (*AssignUniqueClientIDResponse, error)
func (UnimplementedImapConcentratorServer) DeleteMailboxV1 ¶
func (UnimplementedImapConcentratorServer) DeleteMailboxV1(context.Context, *DeleteMailboxV1Request) (*Ack, error)
func (UnimplementedImapConcentratorServer) GetMailboxV1 ¶
func (UnimplementedImapConcentratorServer) GetMailboxV1(context.Context, *GetMailboxV1Request) (*GetMailboxV1Response, error)
func (UnimplementedImapConcentratorServer) InsertChatV1 ¶
func (UnimplementedImapConcentratorServer) InsertChatV1(context.Context, *InsertChatV1Request) (*Ack, error)
func (UnimplementedImapConcentratorServer) InsertMailboxV1 ¶
func (UnimplementedImapConcentratorServer) InsertMailboxV1(context.Context, *InsertMailboxV1Request) (*Ack, error)
func (UnimplementedImapConcentratorServer) ListMailboxesV1 ¶
func (UnimplementedImapConcentratorServer) ListMailboxesV1(context.Context, *ListMailboxesV1Request) (*ListMailboxesV1Response, error)
func (UnimplementedImapConcentratorServer) PollV1 ¶
func (UnimplementedImapConcentratorServer) PollV1(context.Context, *PollV1Request) (*Ack, error)
func (UnimplementedImapConcentratorServer) SubscribeToAllNotificationsV1 ¶
func (UnimplementedImapConcentratorServer) SubscribeToAllNotificationsV1(*SubscribeToAllNotificationsV1Request, ImapConcentrator_SubscribeToAllNotificationsV1Server) error
func (UnimplementedImapConcentratorServer) SubscribeToChatNotificationsV1 ¶
func (UnimplementedImapConcentratorServer) SubscribeToChatNotificationsV1(*SubscribeToChatNotificationsV1Request, ImapConcentrator_SubscribeToChatNotificationsV1Server) error
func (UnimplementedImapConcentratorServer) UnsubscribeFromNotificationsV1 ¶
func (UnimplementedImapConcentratorServer) UnsubscribeFromNotificationsV1(context.Context, *UnsubscribeFromNotificationsV1Request) (*Ack, error)
func (UnimplementedImapConcentratorServer) UpdateMailboxV1 ¶
func (UnimplementedImapConcentratorServer) UpdateMailboxV1(context.Context, *UpdateMailboxV1Request) (*Ack, error)
type UnsafeImapConcentratorServer ¶
type UnsafeImapConcentratorServer interface {
// contains filtered or unexported methods
}
UnsafeImapConcentratorServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ImapConcentratorServer will result in compilation errors.
type UnsubscribeFromNotificationsV1Request ¶
type UnsubscribeFromNotificationsV1Request struct { ClientID int64 `protobuf:"varint,1,opt,name=clientID,proto3" json:"clientID,omitempty"` // contains filtered or unexported fields }
Graceful unsubscription.
func (*UnsubscribeFromNotificationsV1Request) Descriptor
deprecated
func (*UnsubscribeFromNotificationsV1Request) Descriptor() ([]byte, []int)
Deprecated: Use UnsubscribeFromNotificationsV1Request.ProtoReflect.Descriptor instead.
func (*UnsubscribeFromNotificationsV1Request) GetClientID ¶
func (x *UnsubscribeFromNotificationsV1Request) GetClientID() int64
func (*UnsubscribeFromNotificationsV1Request) ProtoMessage ¶
func (*UnsubscribeFromNotificationsV1Request) ProtoMessage()
func (*UnsubscribeFromNotificationsV1Request) ProtoReflect ¶
func (x *UnsubscribeFromNotificationsV1Request) ProtoReflect() protoreflect.Message
func (*UnsubscribeFromNotificationsV1Request) Reset ¶
func (x *UnsubscribeFromNotificationsV1Request) Reset()
func (*UnsubscribeFromNotificationsV1Request) String ¶
func (x *UnsubscribeFromNotificationsV1Request) String() string
type UpdateMailboxV1Request ¶
type UpdateMailboxV1Request struct { ChatID int64 `protobuf:"varint,1,opt,name=chatID,proto3" json:"chatID,omitempty"` Mailbox *MailboxV1 `protobuf:"bytes,2,opt,name=mailbox,proto3" json:"mailbox,omitempty"` // contains filtered or unexported fields }
Request to update mailbox with given database id from tracking list.
func (*UpdateMailboxV1Request) Descriptor
deprecated
func (*UpdateMailboxV1Request) Descriptor() ([]byte, []int)
Deprecated: Use UpdateMailboxV1Request.ProtoReflect.Descriptor instead.
func (*UpdateMailboxV1Request) GetChatID ¶
func (x *UpdateMailboxV1Request) GetChatID() int64
func (*UpdateMailboxV1Request) GetMailbox ¶
func (x *UpdateMailboxV1Request) GetMailbox() *MailboxV1
func (*UpdateMailboxV1Request) ProtoMessage ¶
func (*UpdateMailboxV1Request) ProtoMessage()
func (*UpdateMailboxV1Request) ProtoReflect ¶
func (x *UpdateMailboxV1Request) ProtoReflect() protoreflect.Message
func (*UpdateMailboxV1Request) Reset ¶
func (x *UpdateMailboxV1Request) Reset()
func (*UpdateMailboxV1Request) String ¶
func (x *UpdateMailboxV1Request) String() string