Documentation ¶
Index ¶
- Constants
- func Logger() twirp.ServerOption
- func RequireAdminAuthSession() twirp.ServerOption
- func RequireAuthSession() twirp.ServerOption
- type Admin
- func (a *Admin) CreateDevice(ctx context.Context, req *rpc.CreateDeviceReq) (*rpc.CreateDeviceResp, error)
- func (a *Admin) CreateEventRule(ctx context.Context, req *rpc.CreateEventRuleReq) (*rpc.CreateEventRuleResp, error)
- func (a *Admin) CreateGroup(ctx context.Context, req *rpc.CreateGroupReq) (*rpc.CreateGroupResp, error)
- func (a *Admin) CreateUser(ctx context.Context, req *rpc.CreateUserReq) (*emptypb.Empty, error)
- func (a *Admin) DeleteDevice(ctx context.Context, req *rpc.DeleteDeviceReq) (*emptypb.Empty, error)
- func (a *Admin) DeleteEventRules(ctx context.Context, req *rpc.DeleteEventRulesReq) (*emptypb.Empty, error)
- func (a *Admin) DeleteEvents(ctx context.Context, _ *emptypb.Empty) (*emptypb.Empty, error)
- func (a *Admin) DeleteGroup(ctx context.Context, req *rpc.DeleteGroupReq) (*emptypb.Empty, error)
- func (a *Admin) DeleteUser(ctx context.Context, req *rpc.DeleteUserReq) (*emptypb.Empty, error)
- func (a *Admin) GetAdminDevicesIDPage(ctx context.Context, req *rpc.GetAdminDevicesIDPageReq) (*rpc.GetAdminDevicesIDPageResp, error)
- func (a *Admin) GetAdminDevicesPage(ctx context.Context, req *rpc.GetAdminDevicesPageReq) (*rpc.GetAdminDevicesPageResp, error)
- func (a *Admin) GetAdminEventsPage(ctx context.Context, _ *emptypb.Empty) (*rpc.GetAdminEventsPageResp, error)
- func (a *Admin) GetAdminGroupsIDPage(ctx context.Context, req *rpc.GetAdminGroupsIDPageReq) (*rpc.GetAdminGroupsIDPageResp, error)
- func (a *Admin) GetAdminGroupsPage(ctx context.Context, req *rpc.GetAdminGroupsPageReq) (*rpc.GetAdminGroupsPageResp, error)
- func (a *Admin) GetAdminUsersPage(ctx context.Context, req *rpc.GetAdminUsersPageReq) (*rpc.GetAdminUsersPageResp, error)
- func (a *Admin) GetDevice(ctx context.Context, req *rpc.GetDeviceReq) (*rpc.GetDeviceResp, error)
- func (a *Admin) GetGroup(ctx context.Context, req *rpc.GetGroupReq) (*rpc.GetGroupResp, error)
- func (a *Admin) GetUser(ctx context.Context, req *rpc.GetUserReq) (*rpc.GetUserResp, error)
- func (*Admin) ListDeviceFeatures(context.Context, *emptypb.Empty) (*rpc.ListDeviceFeaturesResp, error)
- func (a *Admin) ListEventRules(ctx context.Context, _ *emptypb.Empty) (*rpc.ListEventRulesResp, error)
- func (*Admin) ListLocations(context.Context, *emptypb.Empty) (*rpc.ListLocationsResp, error)
- func (a *Admin) ResetUserPassword(ctx context.Context, req *rpc.ResetUserPasswordReq) (*emptypb.Empty, error)
- func (a *Admin) SetDeviceDisable(ctx context.Context, req *rpc.SetDeviceDisableReq) (*emptypb.Empty, error)
- func (a *Admin) SetGroupDisable(ctx context.Context, req *rpc.SetGroupDisableReq) (*emptypb.Empty, error)
- func (a *Admin) SetUserAdmin(ctx context.Context, req *rpc.SetUserAdminReq) (*emptypb.Empty, error)
- func (a *Admin) SetUserDisable(ctx context.Context, req *rpc.SetUserDisableReq) (*emptypb.Empty, error)
- func (a *Admin) UpdateConfig(cfg context.Context, req *rpc.UpdateConfigReq) (*emptypb.Empty, error)
- func (a *Admin) UpdateDevice(ctx context.Context, req *rpc.UpdateDeviceReq) (*emptypb.Empty, error)
- func (a *Admin) UpdateEventRule(ctx context.Context, req *rpc.UpdateEventRuleReq) (*emptypb.Empty, error)
- func (a *Admin) UpdateGroup(ctx context.Context, req *rpc.UpdateGroupReq) (*emptypb.Empty, error)
- func (a *Admin) UpdateUser(ctx context.Context, req *rpc.UpdateUserReq) (*emptypb.Empty, error)
- type HelloWorld
- type Public
- type Server
- type TwirpHandler
- type User
- func (u *User) GetDeviceDetail(ctx context.Context, req *rpc.GetDeviceDetailReq) (*rpc.GetDeviceDetailResp, error)
- func (u *User) GetDeviceRPCStatus(ctx context.Context, req *rpc.GetDeviceRPCStatusReq) (*rpc.GetDeviceRPCStatusResp, error)
- func (u *User) GetDeviceSoftwareVersion(ctx context.Context, req *rpc.GetDeviceSoftwareVersionReq) (*rpc.GetDeviceSoftwareVersionResp, error)
- func (u *User) GetDeviceUptime(ctx context.Context, req *rpc.GetDeviceUptimeReq) (*rpc.GetDeviceUptimeResp, error)
- func (u *User) GetDevicesPage(ctx context.Context, req *rpc.GetDevicesPageReq) (*rpc.GetDevicesPageResp, error)
- func (u *User) GetEmailsIDPage(ctx context.Context, req *rpc.GetEmailsIDPageReq) (*rpc.GetEmailsIDPageResp, error)
- func (u *User) GetEmailsPage(ctx context.Context, req *rpc.GetEmailsPageReq) (*rpc.GetEmailsPageResp, error)
- func (u *User) GetEventsPage(ctx context.Context, req *rpc.GetEventsPageReq) (*rpc.GetEventsPageResp, error)
- func (u *User) GetFileMonthCount(ctx context.Context, req *rpc.GetFileMonthCountReq) (*rpc.GetFileMonthCountResp, error)
- func (u *User) GetFilesPage(ctx context.Context, req *rpc.GetFilesPageReq) (*rpc.GetFilesPageResp, error)
- func (u *User) GetHomePage(ctx context.Context, _ *emptypb.Empty) (*rpc.GetHomePageResp, error)
- func (u *User) GetProfilePage(ctx context.Context, _ *emptypb.Empty) (*rpc.GetProfilePageResp, error)
- func (u *User) ListDeviceLicenses(ctx context.Context, req *rpc.ListDeviceLicensesReq) (*rpc.ListDeviceLicensesResp, error)
- func (u *User) ListDeviceStorage(ctx context.Context, req *rpc.ListDeviceStorageReq) (*rpc.ListDeviceStorageResp, error)
- func (u *User) ListDeviceStreams(ctx context.Context, req *rpc.ListDeviceStreamsReq) (*rpc.ListDeviceStreamsResp, error)
- func (u *User) ListDevices(ctx context.Context, _ *emptypb.Empty) (*rpc.ListDevicesResp, error)
- func (u *User) ListEmailAlarmEvents(ctx context.Context, _ *emptypb.Empty) (*rpc.ListEmailAlarmEventsResp, error)
- func (u *User) ListEventFilters(ctx context.Context, _ *emptypb.Empty) (*rpc.ListEventFiltersResp, error)
- func (u *User) ListLatestFiles(ctx context.Context, _ *emptypb.Empty) (*rpc.ListLatestFilesResp, error)
- func (u *User) RevokeAllMySessions(ctx context.Context, rCreateUpdateGroupeq *emptypb.Empty) (*emptypb.Empty, error)
- func (u *User) RevokeMySession(ctx context.Context, req *rpc.RevokeMySessionReq) (*emptypb.Empty, error)
- func (u *User) UpdateMyPassword(ctx context.Context, req *rpc.UpdateMyPasswordReq) (*emptypb.Empty, error)
- func (u *User) UpdateMyUsername(ctx context.Context, req *rpc.UpdateMyUsernameReq) (*emptypb.Empty, error)
Constants ¶
View Source
const Route = "/twirp"
Variables ¶
This section is empty.
Functions ¶
func Logger ¶
func Logger() twirp.ServerOption
func RequireAdminAuthSession ¶
func RequireAdminAuthSession() twirp.ServerOption
RequireAuthSession allows only valid admin sessions.
func RequireAuthSession ¶
func RequireAuthSession() twirp.ServerOption
RequireAuthSession allows only valid sessions.
Types ¶
type Admin ¶
type Admin struct {
// contains filtered or unexported fields
}
func (*Admin) CreateDevice ¶
func (a *Admin) CreateDevice(ctx context.Context, req *rpc.CreateDeviceReq) (*rpc.CreateDeviceResp, error)
func (*Admin) CreateEventRule ¶
func (a *Admin) CreateEventRule(ctx context.Context, req *rpc.CreateEventRuleReq) (*rpc.CreateEventRuleResp, error)
func (*Admin) CreateGroup ¶
func (a *Admin) CreateGroup(ctx context.Context, req *rpc.CreateGroupReq) (*rpc.CreateGroupResp, error)
func (*Admin) CreateUser ¶
func (*Admin) DeleteDevice ¶
func (*Admin) DeleteEventRules ¶
func (*Admin) DeleteEvents ¶
func (*Admin) DeleteGroup ¶
func (*Admin) DeleteUser ¶
func (*Admin) GetAdminDevicesIDPage ¶
func (a *Admin) GetAdminDevicesIDPage(ctx context.Context, req *rpc.GetAdminDevicesIDPageReq) (*rpc.GetAdminDevicesIDPageResp, error)
func (*Admin) GetAdminDevicesPage ¶
func (a *Admin) GetAdminDevicesPage(ctx context.Context, req *rpc.GetAdminDevicesPageReq) (*rpc.GetAdminDevicesPageResp, error)
func (*Admin) GetAdminEventsPage ¶
func (*Admin) GetAdminGroupsIDPage ¶
func (a *Admin) GetAdminGroupsIDPage(ctx context.Context, req *rpc.GetAdminGroupsIDPageReq) (*rpc.GetAdminGroupsIDPageResp, error)
func (*Admin) GetAdminGroupsPage ¶
func (a *Admin) GetAdminGroupsPage(ctx context.Context, req *rpc.GetAdminGroupsPageReq) (*rpc.GetAdminGroupsPageResp, error)
func (*Admin) GetAdminUsersPage ¶
func (a *Admin) GetAdminUsersPage(ctx context.Context, req *rpc.GetAdminUsersPageReq) (*rpc.GetAdminUsersPageResp, error)
func (*Admin) GetDevice ¶
func (a *Admin) GetDevice(ctx context.Context, req *rpc.GetDeviceReq) (*rpc.GetDeviceResp, error)
func (*Admin) GetGroup ¶
func (a *Admin) GetGroup(ctx context.Context, req *rpc.GetGroupReq) (*rpc.GetGroupResp, error)
func (*Admin) GetUser ¶
func (a *Admin) GetUser(ctx context.Context, req *rpc.GetUserReq) (*rpc.GetUserResp, error)
func (*Admin) ListDeviceFeatures ¶
func (*Admin) ListEventRules ¶
func (*Admin) ListLocations ¶
func (*Admin) ResetUserPassword ¶
func (*Admin) SetDeviceDisable ¶
func (*Admin) SetGroupDisable ¶
func (*Admin) SetUserAdmin ¶
func (*Admin) SetUserDisable ¶
func (*Admin) UpdateConfig ¶
func (*Admin) UpdateDevice ¶
func (*Admin) UpdateEventRule ¶
func (*Admin) UpdateGroup ¶
func (*Admin) UpdateUser ¶
type HelloWorld ¶
type HelloWorld struct { }
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (Server) Register ¶
func (s Server) Register(t TwirpHandler, middleware ...echo.MiddlewareFunc) Server
type TwirpHandler ¶
type User ¶
type User struct {
// contains filtered or unexported fields
}
func (*User) GetDeviceDetail ¶
func (u *User) GetDeviceDetail(ctx context.Context, req *rpc.GetDeviceDetailReq) (*rpc.GetDeviceDetailResp, error)
func (*User) GetDeviceRPCStatus ¶
func (u *User) GetDeviceRPCStatus(ctx context.Context, req *rpc.GetDeviceRPCStatusReq) (*rpc.GetDeviceRPCStatusResp, error)
func (*User) GetDeviceSoftwareVersion ¶
func (u *User) GetDeviceSoftwareVersion(ctx context.Context, req *rpc.GetDeviceSoftwareVersionReq) (*rpc.GetDeviceSoftwareVersionResp, error)
func (*User) GetDeviceUptime ¶
func (u *User) GetDeviceUptime(ctx context.Context, req *rpc.GetDeviceUptimeReq) (*rpc.GetDeviceUptimeResp, error)
func (*User) GetDevicesPage ¶
func (u *User) GetDevicesPage(ctx context.Context, req *rpc.GetDevicesPageReq) (*rpc.GetDevicesPageResp, error)
func (*User) GetEmailsIDPage ¶
func (u *User) GetEmailsIDPage(ctx context.Context, req *rpc.GetEmailsIDPageReq) (*rpc.GetEmailsIDPageResp, error)
func (*User) GetEmailsPage ¶
func (u *User) GetEmailsPage(ctx context.Context, req *rpc.GetEmailsPageReq) (*rpc.GetEmailsPageResp, error)
func (*User) GetEventsPage ¶
func (u *User) GetEventsPage(ctx context.Context, req *rpc.GetEventsPageReq) (*rpc.GetEventsPageResp, error)
func (*User) GetFileMonthCount ¶
func (u *User) GetFileMonthCount(ctx context.Context, req *rpc.GetFileMonthCountReq) (*rpc.GetFileMonthCountResp, error)
func (*User) GetFilesPage ¶
func (u *User) GetFilesPage(ctx context.Context, req *rpc.GetFilesPageReq) (*rpc.GetFilesPageResp, error)
func (*User) GetHomePage ¶
func (*User) GetProfilePage ¶
func (*User) ListDeviceLicenses ¶
func (u *User) ListDeviceLicenses(ctx context.Context, req *rpc.ListDeviceLicensesReq) (*rpc.ListDeviceLicensesResp, error)
func (*User) ListDeviceStorage ¶
func (u *User) ListDeviceStorage(ctx context.Context, req *rpc.ListDeviceStorageReq) (*rpc.ListDeviceStorageResp, error)
func (*User) ListDeviceStreams ¶
func (u *User) ListDeviceStreams(ctx context.Context, req *rpc.ListDeviceStreamsReq) (*rpc.ListDeviceStreamsResp, error)
func (*User) ListDevices ¶
func (*User) ListEmailAlarmEvents ¶
func (*User) ListEventFilters ¶
func (*User) ListLatestFiles ¶
func (*User) RevokeAllMySessions ¶
func (*User) RevokeMySession ¶
func (*User) UpdateMyPassword ¶
func (*User) UpdateMyUsername ¶
Click to show internal directories.
Click to hide internal directories.