package
0.8.0
Repository: https://github.com/onvio/gophish.git
Documentation: pkg.go.dev

# Functions

JSONResponse attempts to set the status code, c, and marshal the given interface, d, into a response that is written to the given ResponseWriter.
NewServer returns a new instance of the API handler with the provided options applied.
WithWorker is an option that sets the background worker.

# Variables

ErrEmptyPassword is thrown when a user provides a blank password to the register or change password functions.
ErrEmptyRole is throws when no role is provided when creating or modifying a user.
ErrEmptyUsername is thrown when a user attempts to register a username that is taken.
ErrInsufficientPermission is thrown when a user attempts to change an attribute (such as the role) for which they don't have permission.
ErrUsernameTaken is thrown when a user attempts to register a username that is taken.

# Structs

Server represents the routes and functionality of the Gophish API.

# Type aliases

ServerOption is an option to apply to the API server.