// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.6
// 	protoc        v3.19.0
// source: interservice/id_token/id_token.proto

package id_token

import (
	context "context"
	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"
	sync "sync"
	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)
)

type ValidateIdTokenRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// id_token
	Token         string `protobuf:"bytes,1,opt,name=token,proto3" json:"token,omitempty" toml:"token,omitempty" mapstructure:"token,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ValidateIdTokenRequest) Reset() {
	*x = ValidateIdTokenRequest{}
	mi := &file_interservice_id_token_id_token_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *ValidateIdTokenRequest) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*ValidateIdTokenRequest) ProtoMessage() {}

func (x *ValidateIdTokenRequest) ProtoReflect() protoreflect.Message {
	mi := &file_interservice_id_token_id_token_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use ValidateIdTokenRequest.ProtoReflect.Descriptor instead.
func (*ValidateIdTokenRequest) Descriptor() ([]byte, []int) {
	return file_interservice_id_token_id_token_proto_rawDescGZIP(), []int{0}
}

func (x *ValidateIdTokenRequest) GetToken() string {
	if x != nil {
		return x.Token
	}
	return ""
}

type ValidateIdTokenResponse struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	IsInvalid     bool                   `protobuf:"varint,1,opt,name=is_invalid,json=isInvalid,proto3" json:"is_invalid,omitempty" toml:"is_invalid,omitempty" mapstructure:"is_invalid,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *ValidateIdTokenResponse) Reset() {
	*x = ValidateIdTokenResponse{}
	mi := &file_interservice_id_token_id_token_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *ValidateIdTokenResponse) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*ValidateIdTokenResponse) ProtoMessage() {}

func (x *ValidateIdTokenResponse) ProtoReflect() protoreflect.Message {
	mi := &file_interservice_id_token_id_token_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use ValidateIdTokenResponse.ProtoReflect.Descriptor instead.
func (*ValidateIdTokenResponse) Descriptor() ([]byte, []int) {
	return file_interservice_id_token_id_token_proto_rawDescGZIP(), []int{1}
}

func (x *ValidateIdTokenResponse) GetIsInvalid() bool {
	if x != nil {
		return x.IsInvalid
	}
	return false
}

var File_interservice_id_token_id_token_proto protoreflect.FileDescriptor

const file_interservice_id_token_id_token_proto_rawDesc = "" +
	"\n" +
	"$interservice/id_token/id_token.proto\x12\x1dchef.automate.domain.id_token\".\n" +
	"\x16ValidateIdTokenRequest\x12\x14\n" +
	"\x05token\x18\x01 \x01(\tR\x05token\"8\n" +
	"\x17ValidateIdTokenResponse\x12\x1d\n" +
	"\n" +
	"is_invalid\x18\x01 \x01(\bR\tisInvalid2\x9d\x01\n" +
	"\x16ValidateIdTokenService\x12\x82\x01\n" +
	"\x0fValidateIdToken\x125.chef.automate.domain.id_token.ValidateIdTokenRequest\x1a6.chef.automate.domain.id_token.ValidateIdTokenResponse\"\x00B4Z2github.com/chef/automate/api/interservice/id_tokenb\x06proto3"

var (
	file_interservice_id_token_id_token_proto_rawDescOnce sync.Once
	file_interservice_id_token_id_token_proto_rawDescData []byte
)

func file_interservice_id_token_id_token_proto_rawDescGZIP() []byte {
	file_interservice_id_token_id_token_proto_rawDescOnce.Do(func() {
		file_interservice_id_token_id_token_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_interservice_id_token_id_token_proto_rawDesc), len(file_interservice_id_token_id_token_proto_rawDesc)))
	})
	return file_interservice_id_token_id_token_proto_rawDescData
}

var file_interservice_id_token_id_token_proto_msgTypes = make([]protoimpl.MessageInfo, 2)
var file_interservice_id_token_id_token_proto_goTypes = []any{
	(*ValidateIdTokenRequest)(nil),  // 0: chef.automate.domain.id_token.ValidateIdTokenRequest
	(*ValidateIdTokenResponse)(nil), // 1: chef.automate.domain.id_token.ValidateIdTokenResponse
}
var file_interservice_id_token_id_token_proto_depIdxs = []int32{
	0, // 0: chef.automate.domain.id_token.ValidateIdTokenService.ValidateIdToken:input_type -> chef.automate.domain.id_token.ValidateIdTokenRequest
	1, // 1: chef.automate.domain.id_token.ValidateIdTokenService.ValidateIdToken:output_type -> chef.automate.domain.id_token.ValidateIdTokenResponse
	1, // [1:2] is the sub-list for method output_type
	0, // [0:1] 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_interservice_id_token_id_token_proto_init() }
func file_interservice_id_token_id_token_proto_init() {
	if File_interservice_id_token_id_token_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_interservice_id_token_id_token_proto_rawDesc), len(file_interservice_id_token_id_token_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   2,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_interservice_id_token_id_token_proto_goTypes,
		DependencyIndexes: file_interservice_id_token_id_token_proto_depIdxs,
		MessageInfos:      file_interservice_id_token_id_token_proto_msgTypes,
	}.Build()
	File_interservice_id_token_id_token_proto = out.File
	file_interservice_id_token_id_token_proto_goTypes = nil
	file_interservice_id_token_id_token_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

// ValidateIdTokenServiceClient is the client API for ValidateIdTokenService service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type ValidateIdTokenServiceClient interface {
	ValidateIdToken(ctx context.Context, in *ValidateIdTokenRequest, opts ...grpc.CallOption) (*ValidateIdTokenResponse, error)
}

type validateIdTokenServiceClient struct {
	cc grpc.ClientConnInterface
}

func NewValidateIdTokenServiceClient(cc grpc.ClientConnInterface) ValidateIdTokenServiceClient {
	return &validateIdTokenServiceClient{cc}
}

func (c *validateIdTokenServiceClient) ValidateIdToken(ctx context.Context, in *ValidateIdTokenRequest, opts ...grpc.CallOption) (*ValidateIdTokenResponse, error) {
	out := new(ValidateIdTokenResponse)
	err := c.cc.Invoke(ctx, "/chef.automate.domain.id_token.ValidateIdTokenService/ValidateIdToken", in, out, opts...)
	if err != nil {
		return nil, err
	}
	return out, nil
}

// ValidateIdTokenServiceServer is the server API for ValidateIdTokenService service.
type ValidateIdTokenServiceServer interface {
	ValidateIdToken(context.Context, *ValidateIdTokenRequest) (*ValidateIdTokenResponse, error)
}

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

func (*UnimplementedValidateIdTokenServiceServer) ValidateIdToken(context.Context, *ValidateIdTokenRequest) (*ValidateIdTokenResponse, error) {
	return nil, status.Errorf(codes.Unimplemented, "method ValidateIdToken not implemented")
}

func RegisterValidateIdTokenServiceServer(s *grpc.Server, srv ValidateIdTokenServiceServer) {
	s.RegisterService(&_ValidateIdTokenService_serviceDesc, srv)
}

func _ValidateIdTokenService_ValidateIdToken_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
	in := new(ValidateIdTokenRequest)
	if err := dec(in); err != nil {
		return nil, err
	}
	if interceptor == nil {
		return srv.(ValidateIdTokenServiceServer).ValidateIdToken(ctx, in)
	}
	info := &grpc.UnaryServerInfo{
		Server:     srv,
		FullMethod: "/chef.automate.domain.id_token.ValidateIdTokenService/ValidateIdToken",
	}
	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
		return srv.(ValidateIdTokenServiceServer).ValidateIdToken(ctx, req.(*ValidateIdTokenRequest))
	}
	return interceptor(ctx, in, info, handler)
}

var _ValidateIdTokenService_serviceDesc = grpc.ServiceDesc{
	ServiceName: "chef.automate.domain.id_token.ValidateIdTokenService",
	HandlerType: (*ValidateIdTokenServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "ValidateIdToken",
			Handler:    _ValidateIdTokenService_ValidateIdToken_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "interservice/id_token/id_token.proto",
}
