Documentation
¶
Index ¶
- func New(ctx context.Context, store *store.Store, engine *requests.Engine, ...) (*chi.Mux, error)
- type AuthConfig
- type Config
- type ContextKey
- type Policy
- type PolicyEngine
- type PolicyType
- type ServerImpl
- func (s *ServerImpl) CreateProject(w http.ResponseWriter, r *http.Request)
- func (s *ServerImpl) CreateRequest(w http.ResponseWriter, r *http.Request)
- func (s *ServerImpl) CreateService(w http.ResponseWriter, r *http.Request)
- func (s *ServerImpl) GetProjectByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
- func (s *ServerImpl) GetProjects(w http.ResponseWriter, r *http.Request, params oapi.GetProjectsParams)
- func (s *ServerImpl) GetRequestByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
- func (s *ServerImpl) GetRequestTemplateSpec(w http.ResponseWriter, r *http.Request, id string)
- func (s *ServerImpl) GetRequestTemplatesForService(w http.ResponseWriter, r *http.Request, id uuid.UUID)
- func (s *ServerImpl) GetRequests(w http.ResponseWriter, r *http.Request, params oapi.GetRequestsParams)
- func (s *ServerImpl) GetServiceByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
- func (s *ServerImpl) GetServices(w http.ResponseWriter, r *http.Request, params oapi.GetServicesParams)
- func (s ServerImpl) GetUserInfo(w http.ResponseWriter, r *http.Request)
- func (s *ServerImpl) GetUsers(w http.ResponseWriter, r *http.Request)
- func (s *ServerImpl) ReviewRequest(w http.ResponseWriter, r *http.Request, id uuid.UUID)
- func (s *ServerImpl) TriggerRequest(w http.ResponseWriter, r *http.Request, id uuid.UUID)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AuthConfig ¶ added in v0.0.8
type Config ¶
type Config struct { DevMode bool `envconfig:"dev"` RedirectURI string `envconfig:"-"` Auth AuthConfig `envconfig:"auth"` }
type ContextKey ¶
type ContextKey string
ContextKey is used to store the auth context value in the request context
type Policy ¶
type Policy struct { Name string Type PolicyType Module string }
type PolicyEngine ¶
type PolicyEngine struct {
Policies map[PolicyType][]Policy
}
func NewPolicyEngine ¶
func NewPolicyEngine() *PolicyEngine
func (PolicyEngine) EvaluateLoginRequest ¶
func (pe PolicyEngine) EvaluateLoginRequest(userInfo oapi.User) (bool, error)
type PolicyType ¶
type PolicyType string
const ( LoginPolicyType PolicyType = "login" AccessPolicyType PolicyType = "access" )
type ServerImpl ¶
type ServerImpl struct {
// contains filtered or unexported fields
}
func (*ServerImpl) CreateProject ¶
func (s *ServerImpl) CreateProject(w http.ResponseWriter, r *http.Request)
func (*ServerImpl) CreateRequest ¶
func (s *ServerImpl) CreateRequest(w http.ResponseWriter, r *http.Request)
func (*ServerImpl) CreateService ¶
func (s *ServerImpl) CreateService(w http.ResponseWriter, r *http.Request)
func (*ServerImpl) GetProjectByID ¶
func (s *ServerImpl) GetProjectByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
func (*ServerImpl) GetProjects ¶
func (s *ServerImpl) GetProjects(w http.ResponseWriter, r *http.Request, params oapi.GetProjectsParams)
func (*ServerImpl) GetRequestByID ¶
func (s *ServerImpl) GetRequestByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
func (*ServerImpl) GetRequestTemplateSpec ¶ added in v0.0.8
func (s *ServerImpl) GetRequestTemplateSpec(w http.ResponseWriter, r *http.Request, id string)
func (*ServerImpl) GetRequestTemplatesForService ¶ added in v0.0.8
func (s *ServerImpl) GetRequestTemplatesForService(w http.ResponseWriter, r *http.Request, id uuid.UUID)
func (*ServerImpl) GetRequests ¶
func (s *ServerImpl) GetRequests(w http.ResponseWriter, r *http.Request, params oapi.GetRequestsParams)
func (*ServerImpl) GetServiceByID ¶
func (s *ServerImpl) GetServiceByID(w http.ResponseWriter, r *http.Request, id uuid.UUID)
func (*ServerImpl) GetServices ¶
func (s *ServerImpl) GetServices(w http.ResponseWriter, r *http.Request, params oapi.GetServicesParams)
func (ServerImpl) GetUserInfo ¶
func (s ServerImpl) GetUserInfo(w http.ResponseWriter, r *http.Request)
func (*ServerImpl) GetUsers ¶ added in v0.0.8
func (s *ServerImpl) GetUsers(w http.ResponseWriter, r *http.Request)
func (*ServerImpl) ReviewRequest ¶
func (s *ServerImpl) ReviewRequest(w http.ResponseWriter, r *http.Request, id uuid.UUID)
func (*ServerImpl) TriggerRequest ¶ added in v0.0.8
func (s *ServerImpl) TriggerRequest(w http.ResponseWriter, r *http.Request, id uuid.UUID)
Source Files
¶
Click to show internal directories.
Click to hide internal directories.