auth

Paddy 2014-12-14 Parent:5bccbed6631b Child:bc77a315f823

100:d03786cbf3ae Go to Latest

auth/request.go

Add authd. Start adding our server implementation. Right now, it's very proof-of-concept stage and will almost certainly be entirely rewritten, but it gets a server up and running.

History
paddy@99 1 package auth
paddy@99 2
paddy@99 3 const (
paddy@99 4 requestErrAccessDenied = "access_denied"
paddy@99 5 requestErrInsufficient = "insufficient"
paddy@99 6 requestErrOverflow = "overflow"
paddy@99 7 requestErrInvalidValue = "invalid_value"
paddy@99 8 requestErrInvalidFormat = "invalid_format"
paddy@99 9 requestErrMissing = "missing"
paddy@99 10 requestErrNotFound = "not_found"
paddy@99 11 requestErrConflig = "conflict"
paddy@99 12 requestErrActOfGod = "act_of_god"
paddy@99 13 )
paddy@99 14
paddy@99 15 type requestError struct {
paddy@99 16 Slug string `json:"error,omitempty"`
paddy@99 17 Field string `json:"field,omitempty"`
paddy@99 18 Param string `json:"param,omitempty"`
paddy@99 19 Header string `json:"header,omitempty"`
paddy@99 20 }