// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.6
// 	protoc        v3.19.0
// source: external/iam/v2/teams.proto

package v2

import (
	context "context"
	_ "github.com/chef/automate/api/external/annotations/iam"
	request "github.com/chef/automate/api/external/iam/v2/request"
	response "github.com/chef/automate/api/external/iam/v2/response"
	_ "github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger/options"
	_ "google.golang.org/genproto/googleapis/api/annotations"
	grpc "google.golang.org/grpc"
	codes "google.golang.org/grpc/codes"
	status "google.golang.org/grpc/status"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	reflect "reflect"
	unsafe "unsafe"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

var File_external_iam_v2_teams_proto protoreflect.FileDescriptor

const file_external_iam_v2_teams_proto_rawDesc = "" +
	"\n" +
	"\x1bexternal/iam/v2/teams.proto\x12\x18chef.automate.api.iam.v2\x1a\x1cgoogle/api/annotations.proto\x1a,protoc-gen-swagger/options/annotations.proto\x1a#external/iam/v2/request/teams.proto\x1a$external/iam/v2/response/teams.proto\x1a*external/annotations/iam/annotations.proto2\xa1\x12\n" +
	"\x05Teams\x12\xb3\x02\n" +
	"\n" +
	"CreateTeam\x12'.chef.automate.api.iam.v2.CreateTeamReq\x1a(.chef.automate.api.iam.v2.CreateTeamResp\"\xd1\x01\x92A\x8f\x01\n" +
	"\x05teamsj\x85\x01\n" +
	"\x0ex-code-samples\x12s2q\n" +
	"o*m\n" +
	"\x0e\n" +
	"\x04lang\x12\x06\x1a\x04JSON\n" +
	"[\n" +
	"\x06source\x12Q\x1aO{\"id\": \"test-id\", \"name\": \"My Test Team\", \"projects\": [\"project1\", \"project2\"]}\x8a\xb5\x18\x1d\n" +
	"\tiam:teams\x12\x10iam:teams:create\x82\xd3\xe4\x93\x02\x17:\x01*\"\x12/apis/iam/v2/teams\x12\xa1\x01\n" +
	"\tListTeams\x12&.chef.automate.api.iam.v2.ListTeamsReq\x1a'.chef.automate.api.iam.v2.ListTeamsResp\"C\x92A\a\n" +
	"\x05teams\x8a\xb5\x18\x1b\n" +
	"\tiam:teams\x12\x0eiam:teams:list\x82\xd3\xe4\x93\x02\x14\x12\x12/apis/iam/v2/teams\x12\xa4\x01\n" +
	"\aGetTeam\x12$.chef.automate.api.iam.v2.GetTeamReq\x1a%.chef.automate.api.iam.v2.GetTeamResp\"L\x92A\a\n" +
	"\x05teams\x8a\xb5\x18\x1f\n" +
	"\x0eiam:teams:{id}\x12\riam:teams:get\x82\xd3\xe4\x93\x02\x19\x12\x17/apis/iam/v2/teams/{id}\x12\xb4\x02\n" +
	"\n" +
	"UpdateTeam\x12'.chef.automate.api.iam.v2.UpdateTeamReq\x1a(.chef.automate.api.iam.v2.UpdateTeamResp\"\xd2\x01\x92A\x86\x01\n" +
	"\x05teamsj}\n" +
	"\x0ex-code-samples\x12k2i\n" +
	"g*e\n" +
	"\x0e\n" +
	"\x04lang\x12\x06\x1a\x04JSON\n" +
	"S\n" +
	"\x06source\x12I\x1aG{\"name\": \"My Update Test Team\", \"projects\": [\"project1\", \"projectnew\"]}\x8a\xb5\x18\"\n" +
	"\x0eiam:teams:{id}\x12\x10iam:teams:update\x82\xd3\xe4\x93\x02\x1c:\x01*\x1a\x17/apis/iam/v2/teams/{id}\x12\xb0\x01\n" +
	"\n" +
	"DeleteTeam\x12'.chef.automate.api.iam.v2.DeleteTeamReq\x1a(.chef.automate.api.iam.v2.DeleteTeamResp\"O\x92A\a\n" +
	"\x05teams\x8a\xb5\x18\"\n" +
	"\x0eiam:teams:{id}\x12\x10iam:teams:delete\x82\xd3\xe4\x93\x02\x19*\x17/apis/iam/v2/teams/{id}\x12\xd3\x01\n" +
	"\x11GetTeamMembership\x12..chef.automate.api.iam.v2.GetTeamMembershipReq\x1a/.chef.automate.api.iam.v2.GetTeamMembershipResp\"]\x92A\a\n" +
	"\x05teams\x8a\xb5\x18*\n" +
	"\x14iam:teams:{id}:users\x12\x12iam:teamUsers:list\x82\xd3\xe4\x93\x02\x1f\x12\x1d/apis/iam/v2/teams/{id}/users\x12\xee\x02\n" +
	"\x0eAddTeamMembers\x12+.chef.automate.api.iam.v2.AddTeamMembersReq\x1a,.chef.automate.api.iam.v2.AddTeamMembersResp\"\x80\x02\x92A\xa6\x01\n" +
	"\x05teamsj\x9c\x01\n" +
	"\x0ex-code-samples\x12\x89\x012\x86\x01\n" +
	"\x83\x01*\x80\x01\n" +
	"\x0e\n" +
	"\x04lang\x12\x06\x1a\x04JSON\n" +
	"n\n" +
	"\x06source\x12d\x1ab{membership_ids: [\"527ed96f-2ecb-4f8f-abd7-0bf6511459ac\", \"987c8475-5747-4f9b-a766-c337f73965ae\"]}\x8a\xb5\x18&\n" +
	"\x0eiam:teams:{id}\x12\x14iam:teamUsers:create\x82\xd3\xe4\x93\x02&:\x01*\"!/apis/iam/v2/teams/{id}/users:add\x12\xfa\x02\n" +
	"\x11RemoveTeamMembers\x12..chef.automate.api.iam.v2.RemoveTeamMembersReq\x1a/.chef.automate.api.iam.v2.RemoveTeamMembersResp\"\x83\x02\x92A\xa6\x01\n" +
	"\x05teamsj\x9c\x01\n" +
	"\x0ex-code-samples\x12\x89\x012\x86\x01\n" +
	"\x83\x01*\x80\x01\n" +
	"\x0e\n" +
	"\x04lang\x12\x06\x1a\x04JSON\n" +
	"n\n" +
	"\x06source\x12d\x1ab{membership_ids: [\"527ed96f-2ecb-4f8f-abd7-0bf6511459ac\", \"987c8475-5747-4f9b-a766-c337f73965ae\"]}\x8a\xb5\x18&\n" +
	"\x0eiam:teams:{id}\x12\x14iam:teamUsers:delete\x82\xd3\xe4\x93\x02):\x01*\"$/apis/iam/v2/teams/{id}/users:remove\x12\xe8\x01\n" +
	"\x11GetTeamsForMember\x12..chef.automate.api.iam.v2.GetTeamsForMemberReq\x1a/.chef.automate.api.iam.v2.GetTeamsForMemberResp\"r\x92A\a\n" +
	"\x05teams\x8a\xb5\x184\n" +
	"\x1fiam:users:{membership_id}:teams\x12\x11iam:userTeams:get\x82\xd3\xe4\x93\x02*\x12(/apis/iam/v2/users/{membership_id}/teamsB.Z,github.com/chef/automate/api/external/iam/v2b\x06proto3"

var file_external_iam_v2_teams_proto_goTypes = []any{
	(*request.CreateTeamReq)(nil),          // 0: chef.automate.api.iam.v2.CreateTeamReq
	(*request.ListTeamsReq)(nil),           // 1: chef.automate.api.iam.v2.ListTeamsReq
	(*request.GetTeamReq)(nil),             // 2: chef.automate.api.iam.v2.GetTeamReq
	(*request.UpdateTeamReq)(nil),          // 3: chef.automate.api.iam.v2.UpdateTeamReq
	(*request.DeleteTeamReq)(nil),          // 4: chef.automate.api.iam.v2.DeleteTeamReq
	(*request.GetTeamMembershipReq)(nil),   // 5: chef.automate.api.iam.v2.GetTeamMembershipReq
	(*request.AddTeamMembersReq)(nil),      // 6: chef.automate.api.iam.v2.AddTeamMembersReq
	(*request.RemoveTeamMembersReq)(nil),   // 7: chef.automate.api.iam.v2.RemoveTeamMembersReq
	(*request.GetTeamsForMemberReq)(nil),   // 8: chef.automate.api.iam.v2.GetTeamsForMemberReq
	(*response.CreateTeamResp)(nil),        // 9: chef.automate.api.iam.v2.CreateTeamResp
	(*response.ListTeamsResp)(nil),         // 10: chef.automate.api.iam.v2.ListTeamsResp
	(*response.GetTeamResp)(nil),           // 11: chef.automate.api.iam.v2.GetTeamResp
	(*response.UpdateTeamResp)(nil),        // 12: chef.automate.api.iam.v2.UpdateTeamResp
	(*response.DeleteTeamResp)(nil),        // 13: chef.automate.api.iam.v2.DeleteTeamResp
	(*response.GetTeamMembershipResp)(nil), // 14: chef.automate.api.iam.v2.GetTeamMembershipResp
	(*response.AddTeamMembersResp)(nil),    // 15: chef.automate.api.iam.v2.AddTeamMembersResp
	(*response.RemoveTeamMembersResp)(nil), // 16: chef.automate.api.iam.v2.RemoveTeamMembersResp
	(*response.GetTeamsForMemberResp)(nil), // 17: chef.automate.api.iam.v2.GetTeamsForMemberResp
}
var file_external_iam_v2_teams_proto_depIdxs = []int32{
	0,  // 0: chef.automate.api.iam.v2.Teams.CreateTeam:input_type -> chef.automate.api.iam.v2.CreateTeamReq
	1,  // 1: chef.automate.api.iam.v2.Teams.ListTeams:input_type -> chef.automate.api.iam.v2.ListTeamsReq
	2,  // 2: chef.automate.api.iam.v2.Teams.GetTeam:input_type -> chef.automate.api.iam.v2.GetTeamReq
	3,  // 3: chef.automate.api.iam.v2.Teams.UpdateTeam:input_type -> chef.automate.api.iam.v2.UpdateTeamReq
	4,  // 4: chef.automate.api.iam.v2.Teams.DeleteTeam:input_type -> chef.automate.api.iam.v2.DeleteTeamReq
	5,  // 5: chef.automate.api.iam.v2.Teams.GetTeamMembership:input_type -> chef.automate.api.iam.v2.GetTeamMembershipReq
	6,  // 6: chef.automate.api.iam.v2.Teams.AddTeamMembers:input_type -> chef.automate.api.iam.v2.AddTeamMembersReq
	7,  // 7: chef.automate.api.iam.v2.Teams.RemoveTeamMembers:input_type -> chef.automate.api.iam.v2.RemoveTeamMembersReq
	8,  // 8: chef.automate.api.iam.v2.Teams.GetTeamsForMember:input_type -> chef.automate.api.iam.v2.GetTeamsForMemberReq
	9,  // 9: chef.automate.api.iam.v2.Teams.CreateTeam:output_type -> chef.automate.api.iam.v2.CreateTeamResp
	10, // 10: chef.automate.api.iam.v2.Teams.ListTeams:output_type -> chef.automate.api.iam.v2.ListTeamsResp
	11, // 11: chef.automate.api.iam.v2.Teams.GetTeam:output_type -> chef.automate.api.iam.v2.GetTeamResp
	12, // 12: chef.automate.api.iam.v2.Teams.UpdateTeam:output_type -> chef.automate.api.iam.v2.UpdateTeamResp
	13, // 13: chef.automate.api.iam.v2.Teams.DeleteTeam:output_type -> chef.automate.api.iam.v2.DeleteTeamResp
	14, // 14: chef.automate.api.iam.v2.Teams.GetTeamMembership:output_type -> chef.automate.api.iam.v2.GetTeamMembershipResp
	15, // 15: chef.automate.api.iam.v2.Teams.AddTeamMembers:output_type -> chef.automate.api.iam.v2.AddTeamMembersResp
	16, // 16: chef.automate.api.iam.v2.Teams.RemoveTeamMembers:output_type -> chef.automate.api.iam.v2.RemoveTeamMembersResp
	17, // 17: chef.automate.api.iam.v2.Teams.GetTeamsForMember:output_type -> chef.automate.api.iam.v2.GetTeamsForMemberResp
	9,  // [9:18] is the sub-list for method output_type
	0,  // [0:9] is the sub-list for method input_type
	0,  // [0:0] is the sub-list for extension type_name
	0,  // [0:0] is the sub-list for extension extendee
	0,  // [0:0] is the sub-list for field type_name
}

func init() { file_external_iam_v2_teams_proto_init() }
func file_external_iam_v2_teams_proto_init() {
	if File_external_iam_v2_teams_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_external_iam_v2_teams_proto_rawDesc), len(file_external_iam_v2_teams_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   0,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_external_iam_v2_teams_proto_goTypes,
		DependencyIndexes: file_external_iam_v2_teams_proto_depIdxs,
	}.Build()
	File_external_iam_v2_teams_proto = out.File
	file_external_iam_v2_teams_proto_goTypes = nil
	file_external_iam_v2_teams_proto_depIdxs = nil
}

// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConnInterface

// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion6

// TeamsClient is the client API for Teams service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type TeamsClient interface {
	// Creates a local team
	//
	// Creates a local team that is used to group local users as members of IAM policies.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:create
	CreateTeam(ctx context.Context, in *request.CreateTeamReq, opts ...grpc.CallOption) (*response.CreateTeamResp, error)
	// Lists all local teams
	//
	// Lists all local teams.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:list
	ListTeams(ctx context.Context, in *request.ListTeamsReq, opts ...grpc.CallOption) (*response.ListTeamsResp, error)
	// Get a team
	//
	// Returns the details for a team.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:get
	GetTeam(ctx context.Context, in *request.GetTeamReq, opts ...grpc.CallOption) (*response.GetTeamResp, error)
	// Updates a local team
	//
	// Updates a local team.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:update
	UpdateTeam(ctx context.Context, in *request.UpdateTeamReq, opts ...grpc.CallOption) (*response.UpdateTeamResp, error)
	// Deletes a local team
	//
	// Deletes a local team and removes it from any policies.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:delete
	DeleteTeam(ctx context.Context, in *request.DeleteTeamReq, opts ...grpc.CallOption) (*response.DeleteTeamResp, error)
	// Gets local team membership
	//
	// Lists all users of a local team. Users are listed by their membership_id.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:list
	GetTeamMembership(ctx context.Context, in *request.GetTeamMembershipReq, opts ...grpc.CallOption) (*response.GetTeamMembershipResp, error)
	// Adds local team membership
	//
	// Adds a list of users to a local team. Users are added by their membership_id.
	// The request currently does not validate that membership_id maps to a real user.
	//
	// The membership_id for users can be found via GET /apis/apis/iam/v2/users/<user_id>.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:create
	AddTeamMembers(ctx context.Context, in *request.AddTeamMembersReq, opts ...grpc.CallOption) (*response.AddTeamMembersResp, error)
	// Removes local team membership
	//
	// Removes a list of users from a local team. Users are removed by their membership_id.
	// The request currently does not validate that membership_id maps to a real user.
	//
	// The membership_id for users can be found via GET /apis/apis/iam/v2/users/<user_id>.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:delete
	RemoveTeamMembers(ctx context.Context, in *request.RemoveTeamMembersReq, opts ...grpc.CallOption) (*response.RemoveTeamMembersResp, error)
	// Gets team membership for a user
	//
	// Lists all local teams for a specific user. You must use their membership_id in the request URL.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:userTeams:get
	GetTeamsForMember(ctx context.Context, in *request.GetTeamsForMemberReq, opts ...grpc.CallOption) (*response.GetTeamsForMemberResp, error)
}

type teamsClient struct {
	cc grpc.ClientConnInterface
}

func NewTeamsClient(cc grpc.ClientConnInterface) TeamsClient {
	return &teamsClient{cc}
}

func (c *teamsClient) CreateTeam(ctx context.Context, in *request.CreateTeamReq, opts ...grpc.CallOption) (*response.CreateTeamResp, error) {
	out := new(response.CreateTeamResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/CreateTeam", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) ListTeams(ctx context.Context, in *request.ListTeamsReq, opts ...grpc.CallOption) (*response.ListTeamsResp, error) {
	out := new(response.ListTeamsResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/ListTeams", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) GetTeam(ctx context.Context, in *request.GetTeamReq, opts ...grpc.CallOption) (*response.GetTeamResp, error) {
	out := new(response.GetTeamResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/GetTeam", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) UpdateTeam(ctx context.Context, in *request.UpdateTeamReq, opts ...grpc.CallOption) (*response.UpdateTeamResp, error) {
	out := new(response.UpdateTeamResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/UpdateTeam", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) DeleteTeam(ctx context.Context, in *request.DeleteTeamReq, opts ...grpc.CallOption) (*response.DeleteTeamResp, error) {
	out := new(response.DeleteTeamResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/DeleteTeam", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) GetTeamMembership(ctx context.Context, in *request.GetTeamMembershipReq, opts ...grpc.CallOption) (*response.GetTeamMembershipResp, error) {
	out := new(response.GetTeamMembershipResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/GetTeamMembership", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) AddTeamMembers(ctx context.Context, in *request.AddTeamMembersReq, opts ...grpc.CallOption) (*response.AddTeamMembersResp, error) {
	out := new(response.AddTeamMembersResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/AddTeamMembers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) RemoveTeamMembers(ctx context.Context, in *request.RemoveTeamMembersReq, opts ...grpc.CallOption) (*response.RemoveTeamMembersResp, error) {
	out := new(response.RemoveTeamMembersResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/RemoveTeamMembers", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

func (c *teamsClient) GetTeamsForMember(ctx context.Context, in *request.GetTeamsForMemberReq, opts ...grpc.CallOption) (*response.GetTeamsForMemberResp, error) {
	out := new(response.GetTeamsForMemberResp)
	err := c.cc.Invoke(ctx, "/chef.automate.api.iam.v2.Teams/GetTeamsForMember", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// TeamsServer is the server API for Teams service.
type TeamsServer interface {
	// Creates a local team
	//
	// Creates a local team that is used to group local users as members of IAM policies.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:create
	CreateTeam(context.Context, *request.CreateTeamReq) (*response.CreateTeamResp, error)
	// Lists all local teams
	//
	// Lists all local teams.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:list
	ListTeams(context.Context, *request.ListTeamsReq) (*response.ListTeamsResp, error)
	// Get a team
	//
	// Returns the details for a team.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:get
	GetTeam(context.Context, *request.GetTeamReq) (*response.GetTeamResp, error)
	// Updates a local team
	//
	// Updates a local team.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:update
	UpdateTeam(context.Context, *request.UpdateTeamReq) (*response.UpdateTeamResp, error)
	// Deletes a local team
	//
	// Deletes a local team and removes it from any policies.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teams:delete
	DeleteTeam(context.Context, *request.DeleteTeamReq) (*response.DeleteTeamResp, error)
	// Gets local team membership
	//
	// Lists all users of a local team. Users are listed by their membership_id.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:list
	GetTeamMembership(context.Context, *request.GetTeamMembershipReq) (*response.GetTeamMembershipResp, error)
	// Adds local team membership
	//
	// Adds a list of users to a local team. Users are added by their membership_id.
	// The request currently does not validate that membership_id maps to a real user.
	//
	// The membership_id for users can be found via GET /apis/apis/iam/v2/users/<user_id>.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:create
	AddTeamMembers(context.Context, *request.AddTeamMembersReq) (*response.AddTeamMembersResp, error)
	// Removes local team membership
	//
	// Removes a list of users from a local team. Users are removed by their membership_id.
	// The request currently does not validate that membership_id maps to a real user.
	//
	// The membership_id for users can be found via GET /apis/apis/iam/v2/users/<user_id>.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:teamUsers:delete
	RemoveTeamMembers(context.Context, *request.RemoveTeamMembersReq) (*response.RemoveTeamMembersResp, error)
	// Gets team membership for a user
	//
	// Lists all local teams for a specific user. You must use their membership_id in the request URL.
	//
	// Authorization Action:
	// ```
	// ```
	//
	//iam:userTeams:get
	GetTeamsForMember(context.Context, *request.GetTeamsForMemberReq) (*response.GetTeamsForMemberResp, error)
}

// UnimplementedTeamsServer can be embedded to have forward compatible implementations.
type UnimplementedTeamsServer struct {
}

func (*UnimplementedTeamsServer) CreateTeam(context.Context, *request.CreateTeamReq) (*response.CreateTeamResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method CreateTeam not implemented")
}
func (*UnimplementedTeamsServer) ListTeams(context.Context, *request.ListTeamsReq) (*response.ListTeamsResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ListTeams not implemented")
}
func (*UnimplementedTeamsServer) GetTeam(context.Context, *request.GetTeamReq) (*response.GetTeamResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetTeam not implemented")
}
func (*UnimplementedTeamsServer) UpdateTeam(context.Context, *request.UpdateTeamReq) (*response.UpdateTeamResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method UpdateTeam not implemented")
}
func (*UnimplementedTeamsServer) DeleteTeam(context.Context, *request.DeleteTeamReq) (*response.DeleteTeamResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method DeleteTeam not implemented")
}
func (*UnimplementedTeamsServer) GetTeamMembership(context.Context, *request.GetTeamMembershipReq) (*response.GetTeamMembershipResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetTeamMembership not implemented")
}
func (*UnimplementedTeamsServer) AddTeamMembers(context.Context, *request.AddTeamMembersReq) (*response.AddTeamMembersResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method AddTeamMembers not implemented")
}
func (*UnimplementedTeamsServer) RemoveTeamMembers(context.Context, *request.RemoveTeamMembersReq) (*response.RemoveTeamMembersResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method RemoveTeamMembers not implemented")
}
func (*UnimplementedTeamsServer) GetTeamsForMember(context.Context, *request.GetTeamsForMemberReq) (*response.GetTeamsForMemberResp, error) {
	return nil, status.Errorf(codes.Unimplemented, "method GetTeamsForMember not implemented")
}

func RegisterTeamsServer(s *grpc.Server, srv TeamsServer) {
	s.RegisterService(&_Teams_serviceDesc, srv)
}

func _Teams_CreateTeam_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.CreateTeamReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).CreateTeam(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/CreateTeam",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).CreateTeam(ctx, req.(*request.CreateTeamReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_ListTeams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.ListTeamsReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).ListTeams(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/ListTeams",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).ListTeams(ctx, req.(*request.ListTeamsReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_GetTeam_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.GetTeamReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).GetTeam(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/GetTeam",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).GetTeam(ctx, req.(*request.GetTeamReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_UpdateTeam_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.UpdateTeamReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).UpdateTeam(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/UpdateTeam",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).UpdateTeam(ctx, req.(*request.UpdateTeamReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_DeleteTeam_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.DeleteTeamReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).DeleteTeam(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/DeleteTeam",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).DeleteTeam(ctx, req.(*request.DeleteTeamReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_GetTeamMembership_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.GetTeamMembershipReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).GetTeamMembership(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/GetTeamMembership",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).GetTeamMembership(ctx, req.(*request.GetTeamMembershipReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_AddTeamMembers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.AddTeamMembersReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).AddTeamMembers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/AddTeamMembers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).AddTeamMembers(ctx, req.(*request.AddTeamMembersReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_RemoveTeamMembers_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.RemoveTeamMembersReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).RemoveTeamMembers(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/RemoveTeamMembers",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).RemoveTeamMembers(ctx, req.(*request.RemoveTeamMembersReq))
	}
	return interceptor(ctx, in, info, handler)
}

func _Teams_GetTeamsForMember_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(request.GetTeamsForMemberReq)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(TeamsServer).GetTeamsForMember(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.api.iam.v2.Teams/GetTeamsForMember",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(TeamsServer).GetTeamsForMember(ctx, req.(*request.GetTeamsForMemberReq))
	}
	return interceptor(ctx, in, info, handler)
}

var _Teams_serviceDesc = grpc.ServiceDesc{
	ServiceName: "chef.automate.api.iam.v2.Teams",
	HandlerType: (*TeamsServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "CreateTeam",
			Handler:    _Teams_CreateTeam_Handler,
		},
		{
			MethodName: "ListTeams",
			Handler:    _Teams_ListTeams_Handler,
		},
		{
			MethodName: "GetTeam",
			Handler:    _Teams_GetTeam_Handler,
		},
		{
			MethodName: "UpdateTeam",
			Handler:    _Teams_UpdateTeam_Handler,
		},
		{
			MethodName: "DeleteTeam",
			Handler:    _Teams_DeleteTeam_Handler,
		},
		{
			MethodName: "GetTeamMembership",
			Handler:    _Teams_GetTeamMembership_Handler,
		},
		{
			MethodName: "AddTeamMembers",
			Handler:    _Teams_AddTeamMembers_Handler,
		},
		{
			MethodName: "RemoveTeamMembers",
			Handler:    _Teams_RemoveTeamMembers_Handler,
		},
		{
			MethodName: "GetTeamsForMember",
			Handler:    _Teams_GetTeamsForMember_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "external/iam/v2/teams.proto",
}
