v1

package
v0.0.0-...-0490640 Latest Latest
Warning

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

Go to latest
Published: May 16, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

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

Server is a V1 teams server

func NewServer

func NewServer(service *service.Service) *Server

NewServer returns a V1 Teams server

func (*Server) AddUsers

func (s *Server) AddUsers(ctx context.Context, req *teams.AddUsersReq) (*teams.AddUsersResp, error)

AddUsers associates an array of users with an existing team

func (*Server) CreateTeam

func (s *Server) CreateTeam(ctx context.Context, req *teams.CreateTeamReq) (*teams.CreateTeamResp, error)

CreateTeam creates a new team

func (*Server) DeleteTeam

func (s *Server) DeleteTeam(ctx context.Context, req *teams.DeleteTeamReq) (*teams.DeleteTeamResp, error)

DeleteTeam deletes a team from the db

func (*Server) GetTeam

func (s *Server) GetTeam(ctx context.Context, req *teams.GetTeamReq) (*teams.GetTeamResp, error)

GetTeam takes an ID and returns a team object

func (*Server) GetTeamByName

func (s *Server) GetTeamByName(ctx context.Context,
	req *teams.GetTeamByNameReq) (*teams.GetTeamByNameResp, error)

GetTeamByName looks up a team by its name string. This is intended as a helper for automate-deployment's boostrapping of an initial user and not something we currently have plans to wire into our HTTP API.

func (*Server) GetTeams

func (s *Server) GetTeams(ctx context.Context, req *teams.GetTeamsReq) (*teams.GetTeamsResp, error)

GetTeams returns a list of teams from the db

func (*Server) GetTeamsForUser

func (s *Server) GetTeamsForUser(
	ctx context.Context,
	req *teams.GetTeamsForUserReq,
) (*teams.GetTeamsForUserResp, error)

GetTeamsForUser fetches a list of a user's associated teams

func (*Server) GetUsers

func (s *Server) GetUsers(ctx context.Context,
	req *teams.GetUsersReq) (*teams.GetUsersResp, error)

GetUsers fetches a list of user id's associated with a team

func (*Server) GetVersion

GetVersion returns the version of Teams GRPC API

func (*Server) PurgeUserMembership

func (s *Server) PurgeUserMembership(ctx context.Context,
	req *teams.PurgeUserMembershipReq) (*teams.PurgeUserMembershipResp, error)

PurgeUserMembership removes the user's membership from all teams to which the user belongs and returns that list of teams

func (*Server) RemoveUsers

func (s *Server) RemoveUsers(ctx context.Context, req *teams.RemoveUsersReq) (*teams.RemoveUsersResp, error)

RemoveUsers disassociates an array of users with an existing team.

func (*Server) UpdateTeam

func (s *Server) UpdateTeam(ctx context.Context, req *teams.UpdateTeamReq) (*teams.UpdateTeamResp, error)

UpdateTeam updates a team in the db via post

Jump to

Keyboard shortcuts

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