Documentation ¶
Index ¶
- Constants
- func NewErrorLogger(debug bool) *zerolog.Logger
- func NewInfoLogger(debug bool) *zerolog.Logger
- type Envelope
- type Service
- func (sv *Service) ClientError(w http.ResponseWriter, r *http.Request, status int, message string)
- func (sv *Service) NotFound(w http.ResponseWriter, r *http.Request)
- func (sv *Service) RetrieveSessionToken(r *http.Request) (string, error)
- func (sv *Service) ServerError(w http.ResponseWriter, r *http.Request, err error)
- func (sv *Service) ValidateEmail(email string) bool
- func (sv *Service) WriteJSON(w http.ResponseWriter, status int, data Envelope, headers http.Header) error
- func (sv *Service) WriteMessage(w http.ResponseWriter, r *http.Request, message string)
Constants ¶
View Source
const ( ErrEmptySessionToken = rpcError("the provided session token is empty") ErrFailedRetrievingData = rpcError("failed to retrieve session data") )
Variables ¶
This section is empty.
Functions ¶
func NewErrorLogger ¶
func NewInfoLogger ¶
Types ¶
type Service ¶
func (*Service) ClientError ¶
func (*Service) RetrieveSessionToken ¶
func (*Service) ServerError ¶
func (*Service) ValidateEmail ¶
func (*Service) WriteMessage ¶
Click to show internal directories.
Click to hide internal directories.