// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.2.0
// - protoc             v3.21.9
// source: api/internal.proto

package api

import (
	context "context"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
	emptypb "google.golang.org/protobuf/types/known/emptypb"
)

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.32.0 or later.
const _ = grpc.SupportPackageIsVersion7

// InternalServiceClient is the client API for InternalService 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.
type InternalServiceClient interface {
	// Log in a user
	Login(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error)
	// Get the current user's profile
	Profile(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ProfileResponse, error)
	// Perform a global search.
	GlobalSearch(ctx context.Context, in *GlobalSearchRequest, opts ...grpc.CallOption) (*GlobalSearchResponse, error)
	// CreateApiKey creates the given API key.
	CreateApiKey(ctx context.Context, in *CreateApiKeyRequest, opts ...grpc.CallOption) (*CreateApiKeyResponse, error)
	// DeleteApiKey deletes the API key.
	DeleteApiKey(ctx context.Context, in *DeleteApiKeyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
	// ListApiKeys lists the available API keys.
	ListApiKeys(ctx context.Context, in *ListApiKeysRequest, opts ...grpc.CallOption) (*ListApiKeysResponse, error)
	// Get the global settings.
	Settings(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*SettingsResponse, error)
	// OpenId Connect login.
	OpenIdConnectLogin(ctx context.Context, in *OpenIdConnectLoginRequest, opts ...grpc.CallOption) (*OpenIdConnectLoginResponse, error)
	// GetDevicesSummary returns an aggregated summary of the devices.
	GetDevicesSummary(ctx context.Context, in *GetDevicesSummaryRequest, opts ...grpc.CallOption) (*GetDevicesSummaryResponse, error)
	// GetGatewaysSummary returns an aggregated summary of the gateways.
	GetGatewaysSummary(ctx context.Context, in *GetGatewaysSummaryRequest, opts ...grpc.CallOption) (*GetGatewaysSummaryResponse, error)
	// Stream frame for the given Gateway ID.
	StreamGatewayFrames(ctx context.Context, in *StreamGatewayFramesRequest, opts ...grpc.CallOption) (InternalService_StreamGatewayFramesClient, error)
	// Stream frames for the given Device EUI.
	StreamDeviceFrames(ctx context.Context, in *StreamDeviceFramesRequest, opts ...grpc.CallOption) (InternalService_StreamDeviceFramesClient, error)
	// Stream events for the given Device EUI.
	StreamDeviceEvents(ctx context.Context, in *StreamDeviceEventsRequest, opts ...grpc.CallOption) (InternalService_StreamDeviceEventsClient, error)
	// ListRegions lists the available (configured) regions.
	ListRegions(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ListRegionsResponse, error)
	// GetRegion returns the region details for the given region.
	GetRegion(ctx context.Context, in *GetRegionRequest, opts ...grpc.CallOption) (*GetRegionResponse, error)
}

type internalServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewInternalServiceClient(cc grpc.ClientConnInterface) InternalServiceClient {
	return &internalServiceClient{cc}
}

func (c *internalServiceClient) Login(ctx context.Context, in *LoginRequest, opts ...grpc.CallOption) (*LoginResponse, error) {
	out := new(LoginResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/Login", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) Profile(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ProfileResponse, error) {
	out := new(ProfileResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/Profile", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) GlobalSearch(ctx context.Context, in *GlobalSearchRequest, opts ...grpc.CallOption) (*GlobalSearchResponse, error) {
	out := new(GlobalSearchResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/GlobalSearch", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) CreateApiKey(ctx context.Context, in *CreateApiKeyRequest, opts ...grpc.CallOption) (*CreateApiKeyResponse, error) {
	out := new(CreateApiKeyResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/CreateApiKey", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) DeleteApiKey(ctx context.Context, in *DeleteApiKeyRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) {
	out := new(emptypb.Empty)
	err := c.cc.Invoke(ctx, "/api.InternalService/DeleteApiKey", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) ListApiKeys(ctx context.Context, in *ListApiKeysRequest, opts ...grpc.CallOption) (*ListApiKeysResponse, error) {
	out := new(ListApiKeysResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/ListApiKeys", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) Settings(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*SettingsResponse, error) {
	out := new(SettingsResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/Settings", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) OpenIdConnectLogin(ctx context.Context, in *OpenIdConnectLoginRequest, opts ...grpc.CallOption) (*OpenIdConnectLoginResponse, error) {
	out := new(OpenIdConnectLoginResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/OpenIdConnectLogin", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) GetDevicesSummary(ctx context.Context, in *GetDevicesSummaryRequest, opts ...grpc.CallOption) (*GetDevicesSummaryResponse, error) {
	out := new(GetDevicesSummaryResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/GetDevicesSummary", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) GetGatewaysSummary(ctx context.Context, in *GetGatewaysSummaryRequest, opts ...grpc.CallOption) (*GetGatewaysSummaryResponse, error) {
	out := new(GetGatewaysSummaryResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/GetGatewaysSummary", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) StreamGatewayFrames(ctx context.Context, in *StreamGatewayFramesRequest, opts ...grpc.CallOption) (InternalService_StreamGatewayFramesClient, error) {
	stream, err := c.cc.NewStream(ctx, &InternalService_ServiceDesc.Streams[0], "/api.InternalService/StreamGatewayFrames", opts...)
	if err != nil {
		return nil, err
	}
	x := &internalServiceStreamGatewayFramesClient{stream}
	if err := x.ClientStream.SendMsg(in); err != nil {
		return nil, err
	}
	if err := x.ClientStream.CloseSend(); err != nil {
		return nil, err
	}
	return x, nil
}

type InternalService_StreamGatewayFramesClient interface {
	Recv() (*LogItem, error)
	grpc.ClientStream
}

type internalServiceStreamGatewayFramesClient struct {
	grpc.ClientStream
}

func (x *internalServiceStreamGatewayFramesClient) Recv() (*LogItem, error) {
	m := new(LogItem)
	if err := x.ClientStream.RecvMsg(m); err != nil {
		return nil, err
	}
	return m, nil
}

func (c *internalServiceClient) StreamDeviceFrames(ctx context.Context, in *StreamDeviceFramesRequest, opts ...grpc.CallOption) (InternalService_StreamDeviceFramesClient, error) {
	stream, err := c.cc.NewStream(ctx, &InternalService_ServiceDesc.Streams[1], "/api.InternalService/StreamDeviceFrames", opts...)
	if err != nil {
		return nil, err
	}
	x := &internalServiceStreamDeviceFramesClient{stream}
	if err := x.ClientStream.SendMsg(in); err != nil {
		return nil, err
	}
	if err := x.ClientStream.CloseSend(); err != nil {
		return nil, err
	}
	return x, nil
}

type InternalService_StreamDeviceFramesClient interface {
	Recv() (*LogItem, error)
	grpc.ClientStream
}

type internalServiceStreamDeviceFramesClient struct {
	grpc.ClientStream
}

func (x *internalServiceStreamDeviceFramesClient) Recv() (*LogItem, error) {
	m := new(LogItem)
	if err := x.ClientStream.RecvMsg(m); err != nil {
		return nil, err
	}
	return m, nil
}

func (c *internalServiceClient) StreamDeviceEvents(ctx context.Context, in *StreamDeviceEventsRequest, opts ...grpc.CallOption) (InternalService_StreamDeviceEventsClient, error) {
	stream, err := c.cc.NewStream(ctx, &InternalService_ServiceDesc.Streams[2], "/api.InternalService/StreamDeviceEvents", opts...)
	if err != nil {
		return nil, err
	}
	x := &internalServiceStreamDeviceEventsClient{stream}
	if err := x.ClientStream.SendMsg(in); err != nil {
		return nil, err
	}
	if err := x.ClientStream.CloseSend(); err != nil {
		return nil, err
	}
	return x, nil
}

type InternalService_StreamDeviceEventsClient interface {
	Recv() (*LogItem, error)
	grpc.ClientStream
}

type internalServiceStreamDeviceEventsClient struct {
	grpc.ClientStream
}

func (x *internalServiceStreamDeviceEventsClient) Recv() (*LogItem, error) {
	m := new(LogItem)
	if err := x.ClientStream.RecvMsg(m); err != nil {
		return nil, err
	}
	return m, nil
}

func (c *internalServiceClient) ListRegions(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*ListRegionsResponse, error) {
	out := new(ListRegionsResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/ListRegions", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *internalServiceClient) GetRegion(ctx context.Context, in *GetRegionRequest, opts ...grpc.CallOption) (*GetRegionResponse, error) {
	out := new(GetRegionResponse)
	err := c.cc.Invoke(ctx, "/api.InternalService/GetRegion", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// InternalServiceServer is the server API for InternalService service.
// All implementations must embed UnimplementedInternalServiceServer
// for forward compatibility
type InternalServiceServer interface {
	// Log in a user
	Login(context.Context, *LoginRequest) (*LoginResponse, error)
	// Get the current user's profile
	Profile(context.Context, *emptypb.Empty) (*ProfileResponse, error)
	// Perform a global search.
	GlobalSearch(context.Context, *GlobalSearchRequest) (*GlobalSearchResponse, error)
	// CreateApiKey creates the given API key.
	CreateApiKey(context.Context, *CreateApiKeyRequest) (*CreateApiKeyResponse, error)
	// DeleteApiKey deletes the API key.
	DeleteApiKey(context.Context, *DeleteApiKeyRequest) (*emptypb.Empty, error)
	// ListApiKeys lists the available API keys.
	ListApiKeys(context.Context, *ListApiKeysRequest) (*ListApiKeysResponse, error)
	// Get the global settings.
	Settings(context.Context, *emptypb.Empty) (*SettingsResponse, error)
	// OpenId Connect login.
	OpenIdConnectLogin(context.Context, *OpenIdConnectLoginRequest) (*OpenIdConnectLoginResponse, error)
	// GetDevicesSummary returns an aggregated summary of the devices.
	GetDevicesSummary(context.Context, *GetDevicesSummaryRequest) (*GetDevicesSummaryResponse, error)
	// GetGatewaysSummary returns an aggregated summary of the gateways.
	GetGatewaysSummary(context.Context, *GetGatewaysSummaryRequest) (*GetGatewaysSummaryResponse, error)
	// Stream frame for the given Gateway ID.
	StreamGatewayFrames(*StreamGatewayFramesRequest, InternalService_StreamGatewayFramesServer) error
	// Stream frames for the given Device EUI.
	StreamDeviceFrames(*StreamDeviceFramesRequest, InternalService_StreamDeviceFramesServer) error
	// Stream events for the given Device EUI.
	StreamDeviceEvents(*StreamDeviceEventsRequest, InternalService_StreamDeviceEventsServer) error
	// ListRegions lists the available (configured) regions.
	ListRegions(context.Context, *emptypb.Empty) (*ListRegionsResponse, error)
	// GetRegion returns the region details for the given region.
	GetRegion(context.Context, *GetRegionRequest) (*GetRegionResponse, error)
	mustEmbedUnimplementedInternalServiceServer()
}

// UnimplementedInternalServiceServer must be embedded to have forward compatible implementations.
type UnimplementedInternalServiceServer struct {
}

func (UnimplementedInternalServiceServer) Login(context.Context, *LoginRequest) (*LoginResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Login not implemented")
}
func (UnimplementedInternalServiceServer) Profile(context.Context, *emptypb.Empty) (*ProfileResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Profile not implemented")
}
func (UnimplementedInternalServiceServer) GlobalSearch(context.Context, *GlobalSearchRequest) (*GlobalSearchResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GlobalSearch not implemented")
}
func (UnimplementedInternalServiceServer) CreateApiKey(context.Context, *CreateApiKeyRequest) (*CreateApiKeyResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method CreateApiKey not implemented")
}
func (UnimplementedInternalServiceServer) DeleteApiKey(context.Context, *DeleteApiKeyRequest) (*emptypb.Empty, error) {
	return nil, status.Errorf(codes.Unimplemented, "method DeleteApiKey not implemented")
}
func (UnimplementedInternalServiceServer) ListApiKeys(context.Context, *ListApiKeysRequest) (*ListApiKeysResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListApiKeys not implemented")
}
func (UnimplementedInternalServiceServer) Settings(context.Context, *emptypb.Empty) (*SettingsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method Settings not implemented")
}
func (UnimplementedInternalServiceServer) OpenIdConnectLogin(context.Context, *OpenIdConnectLoginRequest) (*OpenIdConnectLoginResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method OpenIdConnectLogin not implemented")
}
func (UnimplementedInternalServiceServer) GetDevicesSummary(context.Context, *GetDevicesSummaryRequest) (*GetDevicesSummaryResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetDevicesSummary not implemented")
}
func (UnimplementedInternalServiceServer) GetGatewaysSummary(context.Context, *GetGatewaysSummaryRequest) (*GetGatewaysSummaryResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetGatewaysSummary not implemented")
}
func (UnimplementedInternalServiceServer) StreamGatewayFrames(*StreamGatewayFramesRequest, InternalService_StreamGatewayFramesServer) error {
	return status.Errorf(codes.Unimplemented, "method StreamGatewayFrames not implemented")
}
func (UnimplementedInternalServiceServer) StreamDeviceFrames(*StreamDeviceFramesRequest, InternalService_StreamDeviceFramesServer) error {
	return status.Errorf(codes.Unimplemented, "method StreamDeviceFrames not implemented")
}
func (UnimplementedInternalServiceServer) StreamDeviceEvents(*StreamDeviceEventsRequest, InternalService_StreamDeviceEventsServer) error {
	return status.Errorf(codes.Unimplemented, "method StreamDeviceEvents not implemented")
}
func (UnimplementedInternalServiceServer) ListRegions(context.Context, *emptypb.Empty) (*ListRegionsResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListRegions not implemented")
}
func (UnimplementedInternalServiceServer) GetRegion(context.Context, *GetRegionRequest) (*GetRegionResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetRegion not implemented")
}
func (UnimplementedInternalServiceServer) mustEmbedUnimplementedInternalServiceServer() {}

// UnsafeInternalServiceServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to InternalServiceServer will
// result in compilation errors.
type UnsafeInternalServiceServer interface {
	mustEmbedUnimplementedInternalServiceServer()
}

func RegisterInternalServiceServer(s grpc.ServiceRegistrar, srv InternalServiceServer) {
	s.RegisterService(&InternalService_ServiceDesc, srv)
}

func _InternalService_Login_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(LoginRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).Login(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/Login",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).Login(ctx, req.(*LoginRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_Profile_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(emptypb.Empty)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).Profile(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/Profile",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).Profile(ctx, req.(*emptypb.Empty))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_GlobalSearch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GlobalSearchRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).GlobalSearch(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/GlobalSearch",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).GlobalSearch(ctx, req.(*GlobalSearchRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_CreateApiKey_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(CreateApiKeyRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).CreateApiKey(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/CreateApiKey",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).CreateApiKey(ctx, req.(*CreateApiKeyRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_DeleteApiKey_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(DeleteApiKeyRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).DeleteApiKey(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/DeleteApiKey",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).DeleteApiKey(ctx, req.(*DeleteApiKeyRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_ListApiKeys_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ListApiKeysRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).ListApiKeys(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/ListApiKeys",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).ListApiKeys(ctx, req.(*ListApiKeysRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_Settings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(emptypb.Empty)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).Settings(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/Settings",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).Settings(ctx, req.(*emptypb.Empty))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_OpenIdConnectLogin_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(OpenIdConnectLoginRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).OpenIdConnectLogin(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/OpenIdConnectLogin",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).OpenIdConnectLogin(ctx, req.(*OpenIdConnectLoginRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_GetDevicesSummary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetDevicesSummaryRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).GetDevicesSummary(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/GetDevicesSummary",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).GetDevicesSummary(ctx, req.(*GetDevicesSummaryRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_GetGatewaysSummary_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetGatewaysSummaryRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).GetGatewaysSummary(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/GetGatewaysSummary",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).GetGatewaysSummary(ctx, req.(*GetGatewaysSummaryRequest))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_StreamGatewayFrames_Handler(srv interface{}, stream grpc.ServerStream) error {
	m := new(StreamGatewayFramesRequest)
	if err := stream.RecvMsg(m); err != nil {
		return err
	}
	return srv.(InternalServiceServer).StreamGatewayFrames(m, &internalServiceStreamGatewayFramesServer{stream})
}

type InternalService_StreamGatewayFramesServer interface {
	Send(*LogItem) error
	grpc.ServerStream
}

type internalServiceStreamGatewayFramesServer struct {
	grpc.ServerStream
}

func (x *internalServiceStreamGatewayFramesServer) Send(m *LogItem) error {
	return x.ServerStream.SendMsg(m)
}

func _InternalService_StreamDeviceFrames_Handler(srv interface{}, stream grpc.ServerStream) error {
	m := new(StreamDeviceFramesRequest)
	if err := stream.RecvMsg(m); err != nil {
		return err
	}
	return srv.(InternalServiceServer).StreamDeviceFrames(m, &internalServiceStreamDeviceFramesServer{stream})
}

type InternalService_StreamDeviceFramesServer interface {
	Send(*LogItem) error
	grpc.ServerStream
}

type internalServiceStreamDeviceFramesServer struct {
	grpc.ServerStream
}

func (x *internalServiceStreamDeviceFramesServer) Send(m *LogItem) error {
	return x.ServerStream.SendMsg(m)
}

func _InternalService_StreamDeviceEvents_Handler(srv interface{}, stream grpc.ServerStream) error {
	m := new(StreamDeviceEventsRequest)
	if err := stream.RecvMsg(m); err != nil {
		return err
	}
	return srv.(InternalServiceServer).StreamDeviceEvents(m, &internalServiceStreamDeviceEventsServer{stream})
}

type InternalService_StreamDeviceEventsServer interface {
	Send(*LogItem) error
	grpc.ServerStream
}

type internalServiceStreamDeviceEventsServer struct {
	grpc.ServerStream
}

func (x *internalServiceStreamDeviceEventsServer) Send(m *LogItem) error {
	return x.ServerStream.SendMsg(m)
}

func _InternalService_ListRegions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(emptypb.Empty)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).ListRegions(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/ListRegions",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).ListRegions(ctx, req.(*emptypb.Empty))
	}
	return interceptor(ctx, in, info, handler)
}

func _InternalService_GetRegion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(GetRegionRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(InternalServiceServer).GetRegion(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/api.InternalService/GetRegion",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(InternalServiceServer).GetRegion(ctx, req.(*GetRegionRequest))
	}
	return interceptor(ctx, in, info, handler)
}

// InternalService_ServiceDesc is the grpc.ServiceDesc for InternalService service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var InternalService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.InternalService",
	HandlerType: (*InternalServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Login",
			Handler:    _InternalService_Login_Handler,
		},
		{
			MethodName: "Profile",
			Handler:    _InternalService_Profile_Handler,
		},
		{
			MethodName: "GlobalSearch",
			Handler:    _InternalService_GlobalSearch_Handler,
		},
		{
			MethodName: "CreateApiKey",
			Handler:    _InternalService_CreateApiKey_Handler,
		},
		{
			MethodName: "DeleteApiKey",
			Handler:    _InternalService_DeleteApiKey_Handler,
		},
		{
			MethodName: "ListApiKeys",
			Handler:    _InternalService_ListApiKeys_Handler,
		},
		{
			MethodName: "Settings",
			Handler:    _InternalService_Settings_Handler,
		},
		{
			MethodName: "OpenIdConnectLogin",
			Handler:    _InternalService_OpenIdConnectLogin_Handler,
		},
		{
			MethodName: "GetDevicesSummary",
			Handler:    _InternalService_GetDevicesSummary_Handler,
		},
		{
			MethodName: "GetGatewaysSummary",
			Handler:    _InternalService_GetGatewaysSummary_Handler,
		},
		{
			MethodName: "ListRegions",
			Handler:    _InternalService_ListRegions_Handler,
		},
		{
			MethodName: "GetRegion",
			Handler:    _InternalService_GetRegion_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "StreamGatewayFrames",
			Handler:       _InternalService_StreamGatewayFrames_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "StreamDeviceFrames",
			Handler:       _InternalService_StreamDeviceFrames_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "StreamDeviceEvents",
			Handler:       _InternalService_StreamDeviceEvents_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "api/internal.proto",
}
