Documentation
¶
Index ¶
- Constants
- Variables
- func New(baseURL url.URL, nex nexus.Nexus, auth authn.Authn, push push.PushNotifier) *api
- func NewProgressSender[T any](w http.ResponseWriter, r *http.Request) (*progressSender[T], bool)
- func ShareFrom(ctx context.Context) *shares.Share
- type API
- type APIRoot
- type CallIncidentParams
- type EntityFunc
- type FilterPagination
- type ID
- type ShareHandlerFunc
- type ShareHandlers
- type ShareRequestType
- type SharedItem
Constants ¶
View Source
const DefaultPerPage = 20
View Source
const (
PrefsMaxBytes = 8192 // 8k
)
Variables ¶
View Source
var ( ErrNoCall = errors.New("no call specified") ErrMustBePlaintext = errors.New("content type must be text/plain") ErrMustBeJSON = errors.New("content type must be application/json") )
View Source
var ( ErrMissingTGSys = errors.New("missing talkgroup ID and system ID") ErrTGIDMismatch = errors.New("url talkgroup ID and document talkgroup ID mismatch") ErrSysMismatch = errors.New("url system ID and document system ID mismatch") ErrNoSuchSystem = tgstore.ErrNoSuchSystem ErrBadSystem = errors.New("invalid system") )
View Source
var (
ErrBadAppName = errors.New("bad app name")
)
View Source
var (
)
Functions ¶
func NewProgressSender ¶
NewProgressSender creates and starts a progressSender. The bool return is whether the connection accepts SSE.
Types ¶
type CallIncidentParams ¶
type EntityFunc ¶
type EntityFunc func(ctx context.Context, id ID) (SharedItem, error)
type FilterPagination ¶
type FilterPagination struct {
tgstore.Pagination
Filter *string `json:"filter"`
}
type ShareHandlerFunc ¶
type ShareHandlerFunc func(id ID, w http.ResponseWriter, r *http.Request)
type ShareHandlers ¶
type ShareHandlers map[ShareRequestType]ShareHandlerFunc
type ShareRequestType ¶
type ShareRequestType string
const ( )
func (ShareRequestType) IsValid ¶
func (rt ShareRequestType) IsValid() bool
type SharedItem ¶
type SharedItem interface {
}
Click to show internal directories.
Click to hide internal directories.