usersv2

package
v0.0.0-...-77c09b6 Latest Latest
Warning

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

Go to latest
Published: May 27, 2024 License: MIT Imports: 21 Imported by: 0

Documentation

Overview

Package usersv2 is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var File_sift_users_v2_users_proto protoreflect.FileDescriptor
View Source
var UserService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "sift.users.v2.UserService",
	HandlerType: (*UserServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "UpdateUserOrganizationActive",
			Handler:    _UserService_UpdateUserOrganizationActive_Handler,
		},
		{
			MethodName: "GetUser",
			Handler:    _UserService_GetUser_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "sift/users/v2/users.proto",
}

UserService_ServiceDesc is the grpc.ServiceDesc for UserService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterUserServiceHandler

func RegisterUserServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterUserServiceHandler registers the http handlers for service UserService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterUserServiceHandlerClient

func RegisterUserServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client UserServiceClient) error

RegisterUserServiceHandlerClient registers the http handlers for service UserService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "UserServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "UserServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "UserServiceClient" to call the correct interceptors.

func RegisterUserServiceHandlerFromEndpoint

func RegisterUserServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterUserServiceHandlerFromEndpoint is same as RegisterUserServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterUserServiceHandlerServer

func RegisterUserServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server UserServiceServer) error

RegisterUserServiceHandlerServer registers the http handlers for service UserService to "mux". UnaryRPC :call UserServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterUserServiceHandlerFromEndpoint instead.

func RegisterUserServiceServer

func RegisterUserServiceServer(s grpc.ServiceRegistrar, srv UserServiceServer)

Types

type GetUserRequest

type GetUserRequest struct {

	// The id of the asset to be retrieved. Required.
	UserId string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	// contains filtered or unexported fields
}

The request for a call to retrieve a single existing user by its user_id.

func (*GetUserRequest) CloneMessageVT

func (m *GetUserRequest) CloneMessageVT() proto.Message

func (*GetUserRequest) CloneVT

func (m *GetUserRequest) CloneVT() *GetUserRequest

func (*GetUserRequest) Descriptor deprecated

func (*GetUserRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetUserRequest.ProtoReflect.Descriptor instead.

func (*GetUserRequest) EqualMessageVT

func (this *GetUserRequest) EqualMessageVT(thatMsg proto.Message) bool

func (*GetUserRequest) EqualVT

func (this *GetUserRequest) EqualVT(that *GetUserRequest) bool

func (*GetUserRequest) GetUserId

func (x *GetUserRequest) GetUserId() string

func (*GetUserRequest) MarshalToSizedBufferVT

func (m *GetUserRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*GetUserRequest) MarshalToSizedBufferVTStrict

func (m *GetUserRequest) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*GetUserRequest) MarshalToVT

func (m *GetUserRequest) MarshalToVT(dAtA []byte) (int, error)

func (*GetUserRequest) MarshalToVTStrict

func (m *GetUserRequest) MarshalToVTStrict(dAtA []byte) (int, error)

func (*GetUserRequest) MarshalVT

func (m *GetUserRequest) MarshalVT() (dAtA []byte, err error)

func (*GetUserRequest) MarshalVTStrict

func (m *GetUserRequest) MarshalVTStrict() (dAtA []byte, err error)

func (*GetUserRequest) ProtoMessage

func (*GetUserRequest) ProtoMessage()

func (*GetUserRequest) ProtoReflect

func (x *GetUserRequest) ProtoReflect() protoreflect.Message

func (*GetUserRequest) Reset

func (x *GetUserRequest) Reset()

func (*GetUserRequest) SizeVT

func (m *GetUserRequest) SizeVT() (n int)

func (*GetUserRequest) String

func (x *GetUserRequest) String() string

func (*GetUserRequest) UnmarshalVT

func (m *GetUserRequest) UnmarshalVT(dAtA []byte) error

func (*GetUserRequest) UnmarshalVTUnsafe

func (m *GetUserRequest) UnmarshalVTUnsafe(dAtA []byte) error

type GetUserResponse

type GetUserResponse struct {
	User *v1.User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
	// contains filtered or unexported fields
}

func (*GetUserResponse) CloneMessageVT

func (m *GetUserResponse) CloneMessageVT() proto.Message

func (*GetUserResponse) CloneVT

func (m *GetUserResponse) CloneVT() *GetUserResponse

func (*GetUserResponse) Descriptor deprecated

func (*GetUserResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetUserResponse.ProtoReflect.Descriptor instead.

func (*GetUserResponse) EqualMessageVT

func (this *GetUserResponse) EqualMessageVT(thatMsg proto.Message) bool

func (*GetUserResponse) EqualVT

func (this *GetUserResponse) EqualVT(that *GetUserResponse) bool

func (*GetUserResponse) GetUser

func (x *GetUserResponse) GetUser() *v1.User

func (*GetUserResponse) MarshalToSizedBufferVT

func (m *GetUserResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*GetUserResponse) MarshalToSizedBufferVTStrict

func (m *GetUserResponse) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*GetUserResponse) MarshalToVT

func (m *GetUserResponse) MarshalToVT(dAtA []byte) (int, error)

func (*GetUserResponse) MarshalToVTStrict

func (m *GetUserResponse) MarshalToVTStrict(dAtA []byte) (int, error)

func (*GetUserResponse) MarshalVT

func (m *GetUserResponse) MarshalVT() (dAtA []byte, err error)

func (*GetUserResponse) MarshalVTStrict

func (m *GetUserResponse) MarshalVTStrict() (dAtA []byte, err error)

func (*GetUserResponse) ProtoMessage

func (*GetUserResponse) ProtoMessage()

func (*GetUserResponse) ProtoReflect

func (x *GetUserResponse) ProtoReflect() protoreflect.Message

func (*GetUserResponse) Reset

func (x *GetUserResponse) Reset()

func (*GetUserResponse) SizeVT

func (m *GetUserResponse) SizeVT() (n int)

func (*GetUserResponse) String

func (x *GetUserResponse) String() string

func (*GetUserResponse) UnmarshalVT

func (m *GetUserResponse) UnmarshalVT(dAtA []byte) error

func (*GetUserResponse) UnmarshalVTUnsafe

func (m *GetUserResponse) UnmarshalVTUnsafe(dAtA []byte) error

type UnimplementedUserServiceServer

type UnimplementedUserServiceServer struct {
}

UnimplementedUserServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedUserServiceServer) GetUser

type UnsafeUserServiceServer

type UnsafeUserServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeUserServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to UserServiceServer will result in compilation errors.

type UpdateUserOrganizationActiveRequest

type UpdateUserOrganizationActiveRequest struct {
	UserId         string `protobuf:"bytes,1,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"`
	OrganizationId string `protobuf:"bytes,2,opt,name=organization_id,json=organizationId,proto3" json:"organization_id,omitempty"`
	Active         bool   `protobuf:"varint,3,opt,name=active,proto3" json:"active,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateUserOrganizationActiveRequest) CloneMessageVT

func (*UpdateUserOrganizationActiveRequest) CloneVT

func (*UpdateUserOrganizationActiveRequest) Descriptor deprecated

func (*UpdateUserOrganizationActiveRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateUserOrganizationActiveRequest.ProtoReflect.Descriptor instead.

func (*UpdateUserOrganizationActiveRequest) EqualMessageVT

func (this *UpdateUserOrganizationActiveRequest) EqualMessageVT(thatMsg proto.Message) bool

func (*UpdateUserOrganizationActiveRequest) EqualVT

func (*UpdateUserOrganizationActiveRequest) GetActive

func (*UpdateUserOrganizationActiveRequest) GetOrganizationId

func (x *UpdateUserOrganizationActiveRequest) GetOrganizationId() string

func (*UpdateUserOrganizationActiveRequest) GetUserId

func (*UpdateUserOrganizationActiveRequest) MarshalToSizedBufferVT

func (m *UpdateUserOrganizationActiveRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveRequest) MarshalToSizedBufferVTStrict

func (m *UpdateUserOrganizationActiveRequest) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveRequest) MarshalToVT

func (m *UpdateUserOrganizationActiveRequest) MarshalToVT(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveRequest) MarshalToVTStrict

func (m *UpdateUserOrganizationActiveRequest) MarshalToVTStrict(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveRequest) MarshalVT

func (m *UpdateUserOrganizationActiveRequest) MarshalVT() (dAtA []byte, err error)

func (*UpdateUserOrganizationActiveRequest) MarshalVTStrict

func (m *UpdateUserOrganizationActiveRequest) MarshalVTStrict() (dAtA []byte, err error)

func (*UpdateUserOrganizationActiveRequest) ProtoMessage

func (*UpdateUserOrganizationActiveRequest) ProtoMessage()

func (*UpdateUserOrganizationActiveRequest) ProtoReflect

func (*UpdateUserOrganizationActiveRequest) Reset

func (*UpdateUserOrganizationActiveRequest) SizeVT

func (m *UpdateUserOrganizationActiveRequest) SizeVT() (n int)

func (*UpdateUserOrganizationActiveRequest) String

func (*UpdateUserOrganizationActiveRequest) UnmarshalVT

func (m *UpdateUserOrganizationActiveRequest) UnmarshalVT(dAtA []byte) error

func (*UpdateUserOrganizationActiveRequest) UnmarshalVTUnsafe

func (m *UpdateUserOrganizationActiveRequest) UnmarshalVTUnsafe(dAtA []byte) error

type UpdateUserOrganizationActiveResponse

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

func (*UpdateUserOrganizationActiveResponse) CloneMessageVT

func (*UpdateUserOrganizationActiveResponse) CloneVT

func (*UpdateUserOrganizationActiveResponse) Descriptor deprecated

func (*UpdateUserOrganizationActiveResponse) Descriptor() ([]byte, []int)

Deprecated: Use UpdateUserOrganizationActiveResponse.ProtoReflect.Descriptor instead.

func (*UpdateUserOrganizationActiveResponse) EqualMessageVT

func (this *UpdateUserOrganizationActiveResponse) EqualMessageVT(thatMsg proto.Message) bool

func (*UpdateUserOrganizationActiveResponse) EqualVT

func (*UpdateUserOrganizationActiveResponse) MarshalToSizedBufferVT

func (m *UpdateUserOrganizationActiveResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveResponse) MarshalToSizedBufferVTStrict

func (m *UpdateUserOrganizationActiveResponse) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveResponse) MarshalToVT

func (m *UpdateUserOrganizationActiveResponse) MarshalToVT(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveResponse) MarshalToVTStrict

func (m *UpdateUserOrganizationActiveResponse) MarshalToVTStrict(dAtA []byte) (int, error)

func (*UpdateUserOrganizationActiveResponse) MarshalVT

func (m *UpdateUserOrganizationActiveResponse) MarshalVT() (dAtA []byte, err error)

func (*UpdateUserOrganizationActiveResponse) MarshalVTStrict

func (m *UpdateUserOrganizationActiveResponse) MarshalVTStrict() (dAtA []byte, err error)

func (*UpdateUserOrganizationActiveResponse) ProtoMessage

func (*UpdateUserOrganizationActiveResponse) ProtoMessage()

func (*UpdateUserOrganizationActiveResponse) ProtoReflect

func (*UpdateUserOrganizationActiveResponse) Reset

func (*UpdateUserOrganizationActiveResponse) SizeVT

func (m *UpdateUserOrganizationActiveResponse) SizeVT() (n int)

func (*UpdateUserOrganizationActiveResponse) String

func (*UpdateUserOrganizationActiveResponse) UnmarshalVT

func (m *UpdateUserOrganizationActiveResponse) UnmarshalVT(dAtA []byte) error

func (*UpdateUserOrganizationActiveResponse) UnmarshalVTUnsafe

func (m *UpdateUserOrganizationActiveResponse) UnmarshalVTUnsafe(dAtA []byte) error

type UserServiceClient

type UserServiceClient interface {
	// Used to toggle a user's active status within their organization.
	UpdateUserOrganizationActive(ctx context.Context, in *UpdateUserOrganizationActiveRequest, opts ...grpc.CallOption) (*UpdateUserOrganizationActiveResponse, error)
	// Retrieves a user object.
	GetUser(ctx context.Context, in *GetUserRequest, opts ...grpc.CallOption) (*GetUserResponse, error)
}

UserServiceClient is the client API for UserService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type UserServiceServer

type UserServiceServer interface {
	// Used to toggle a user's active status within their organization.
	UpdateUserOrganizationActive(context.Context, *UpdateUserOrganizationActiveRequest) (*UpdateUserOrganizationActiveResponse, error)
	// Retrieves a user object.
	GetUser(context.Context, *GetUserRequest) (*GetUserResponse, error)
	// contains filtered or unexported methods
}

UserServiceServer is the server API for UserService service. All implementations must embed UnimplementedUserServiceServer for forward compatibility

Jump to

Keyboard shortcuts

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