org

package
v0.0.0-...-cab28d8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 28, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handlers

type Handlers struct {
	// contains filtered or unexported fields
}

Handlers represents a group of http handlers in charge of handling organizations operations.

func NewHandlers

func NewHandlers(orgManager hub.OrganizationManager, az hub.Authorizer, cfg *viper.Viper) *Handlers

NewHandlers creates a new Handlers instance.

func (*Handlers) Add

func (h *Handlers) Add(w http.ResponseWriter, r *http.Request)

Add is an http handler that adds the provided organization to the database.

func (*Handlers) AddMember

func (h *Handlers) AddMember(w http.ResponseWriter, r *http.Request)

AddMember is an http handler that adds a member to the provided organization.

func (*Handlers) CheckAvailability

func (h *Handlers) CheckAvailability(w http.ResponseWriter, r *http.Request)

CheckAvailability is an http handler that checks the availability of a given value for the provided resource kind.

func (*Handlers) ConfirmMembership

func (h *Handlers) ConfirmMembership(w http.ResponseWriter, r *http.Request)

ConfirmMembership is an http handler used to confirm a user's membership to an organization.

func (*Handlers) Delete

func (h *Handlers) Delete(w http.ResponseWriter, r *http.Request)

Delete is an http handler that deletes an organization.

func (*Handlers) DeleteMember

func (h *Handlers) DeleteMember(w http.ResponseWriter, r *http.Request)

DeleteMember is an http handler that deletes a member from the provided organization.

func (*Handlers) Get

func (h *Handlers) Get(w http.ResponseWriter, r *http.Request)

Get is an http handler that returns the organization requested.

func (*Handlers) GetAuthorizationPolicy

func (h *Handlers) GetAuthorizationPolicy(w http.ResponseWriter, r *http.Request)

GetAuthorizationPolicy is an http handler that returns the organization's authorization policy.

func (*Handlers) GetByUser

func (h *Handlers) GetByUser(w http.ResponseWriter, r *http.Request)

GetByUser is an http handler that returns the organizations the user doing the request belongs to.

func (*Handlers) GetMembers

func (h *Handlers) GetMembers(w http.ResponseWriter, r *http.Request)

GetMembers is an http handler that returns the members of the provided organization.

func (*Handlers) GetUserAllowedActions

func (h *Handlers) GetUserAllowedActions(w http.ResponseWriter, r *http.Request)

GetUserAllowedActions is an http handler that returns the actions the requesting user is allowed to perform in the provided organization.

func (*Handlers) Update

func (h *Handlers) Update(w http.ResponseWriter, r *http.Request)

Update is an http handler that updates the provided organization in the database.

func (*Handlers) UpdateAuthorizationPolicy

func (h *Handlers) UpdateAuthorizationPolicy(w http.ResponseWriter, r *http.Request)

UpdateAuthorizationPolicy is an http handler that updates organization's authorization policy in the database.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL