Documentation ¶
Index ¶
Constants ¶
View Source
const ContextClaims = "token_claims"
ContextClaims is the key used in echo context to store claims
View Source
const ContextPermissionSet = "permissions_set"
ContextPermissionSet is the key used in echo context to store permissions set
Variables ¶
View Source
var ErrPatchCodeOrSet = echo.NewHTTPError(http.StatusBadRequest,
"The patch doc should have property 'codes' or 'permissions', not both")
ErrPatchCodeOrSet is returned when an attempt is made to patch both code & set in one request
Functions ¶
Types ¶
type APIPermission ¶
type APIPermission struct { *permission.Permission // contains filtered or unexported fields }
APIPermission is the struct that will be used to serialized a permission to JSON-API
func (*APIPermission) Included ¶
func (p *APIPermission) Included() []jsonapi.Object
Included implements jsonapi.Doc
func (*APIPermission) Links ¶
func (p *APIPermission) Links() *jsonapi.LinksList
Links implements jsonapi.Doc
func (*APIPermission) MarshalJSON ¶
func (p *APIPermission) MarshalJSON() ([]byte, error)
MarshalJSON implements jsonapi.Doc
func (*APIPermission) Relationships ¶
func (p *APIPermission) Relationships() jsonapi.RelationshipMap
Relationships implements jsonapi.Doc
Click to show internal directories.
Click to hide internal directories.