727 lines
21 KiB
Go
727 lines
21 KiB
Go
// -----------------------------------------------------------------------------
|
|
// File: user.proto
|
|
//
|
|
// This Protocol Buffers file defines the gRPC contract for the UserService.
|
|
// It includes service definitions for creating, retrieving, updating, deleting,
|
|
// and listing users. Each RPC method has corresponding request and response
|
|
// messages. The syntax follows proto3 conventions and uses message types for
|
|
// structured data exchange between microservices.
|
|
//
|
|
// Syntax:
|
|
// - Uses proto3 syntax for modern Protocol Buffers features.
|
|
// - Defines service and message types for CRUD operations.
|
|
// - Supports repeated fields for listing multiple users.
|
|
//
|
|
// Purpose:
|
|
// - Enables strongly-typed, language-agnostic communication between services.
|
|
// - Provides a contract for backend and API Gateway integration.
|
|
// - Facilitates code generation for gRPC servers and clients.
|
|
// -----------------------------------------------------------------------------
|
|
|
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
// versions:
|
|
// protoc-gen-go v1.36.7
|
|
// protoc v6.31.1
|
|
// source: user.proto
|
|
|
|
package userpb
|
|
|
|
import (
|
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
emptypb "google.golang.org/protobuf/types/known/emptypb"
|
|
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 User struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
|
|
Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"`
|
|
Bio string `protobuf:"bytes,4,opt,name=bio,proto3" json:"bio,omitempty"`
|
|
AvatarUrl string `protobuf:"bytes,5,opt,name=avatar_url,json=avatarUrl,proto3" json:"avatar_url,omitempty"`
|
|
CreatedAt int64 `protobuf:"varint,6,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
|
|
UpdatedAt int64 `protobuf:"varint,7,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *User) Reset() {
|
|
*x = User{}
|
|
mi := &file_user_proto_msgTypes[0]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *User) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*User) ProtoMessage() {}
|
|
|
|
func (x *User) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_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 User.ProtoReflect.Descriptor instead.
|
|
func (*User) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{0}
|
|
}
|
|
|
|
func (x *User) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *User) GetUsername() string {
|
|
if x != nil {
|
|
return x.Username
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *User) GetEmail() string {
|
|
if x != nil {
|
|
return x.Email
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *User) GetBio() string {
|
|
if x != nil {
|
|
return x.Bio
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *User) GetAvatarUrl() string {
|
|
if x != nil {
|
|
return x.AvatarUrl
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *User) GetCreatedAt() int64 {
|
|
if x != nil {
|
|
return x.CreatedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *User) GetUpdatedAt() int64 {
|
|
if x != nil {
|
|
return x.UpdatedAt
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type CreateUserRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"`
|
|
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
|
|
Bio string `protobuf:"bytes,3,opt,name=bio,proto3" json:"bio,omitempty"`
|
|
AvatarUrl string `protobuf:"bytes,4,opt,name=avatar_url,json=avatarUrl,proto3" json:"avatar_url,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *CreateUserRequest) Reset() {
|
|
*x = CreateUserRequest{}
|
|
mi := &file_user_proto_msgTypes[1]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *CreateUserRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateUserRequest) ProtoMessage() {}
|
|
|
|
func (x *CreateUserRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_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 CreateUserRequest.ProtoReflect.Descriptor instead.
|
|
func (*CreateUserRequest) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{1}
|
|
}
|
|
|
|
func (x *CreateUserRequest) GetUsername() string {
|
|
if x != nil {
|
|
return x.Username
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateUserRequest) GetEmail() string {
|
|
if x != nil {
|
|
return x.Email
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateUserRequest) GetBio() string {
|
|
if x != nil {
|
|
return x.Bio
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *CreateUserRequest) GetAvatarUrl() string {
|
|
if x != nil {
|
|
return x.AvatarUrl
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type CreateUserResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *CreateUserResponse) Reset() {
|
|
*x = CreateUserResponse{}
|
|
mi := &file_user_proto_msgTypes[2]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *CreateUserResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*CreateUserResponse) ProtoMessage() {}
|
|
|
|
func (x *CreateUserResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[2]
|
|
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 CreateUserResponse.ProtoReflect.Descriptor instead.
|
|
func (*CreateUserResponse) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{2}
|
|
}
|
|
|
|
func (x *CreateUserResponse) GetUser() *User {
|
|
if x != nil {
|
|
return x.User
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type GetUserRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetUserRequest) Reset() {
|
|
*x = GetUserRequest{}
|
|
mi := &file_user_proto_msgTypes[3]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetUserRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetUserRequest) ProtoMessage() {}
|
|
|
|
func (x *GetUserRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[3]
|
|
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 GetUserRequest.ProtoReflect.Descriptor instead.
|
|
func (*GetUserRequest) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{3}
|
|
}
|
|
|
|
func (x *GetUserRequest) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type GetUserResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *GetUserResponse) Reset() {
|
|
*x = GetUserResponse{}
|
|
mi := &file_user_proto_msgTypes[4]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *GetUserResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*GetUserResponse) ProtoMessage() {}
|
|
|
|
func (x *GetUserResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[4]
|
|
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 GetUserResponse.ProtoReflect.Descriptor instead.
|
|
func (*GetUserResponse) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{4}
|
|
}
|
|
|
|
func (x *GetUserResponse) GetUser() *User {
|
|
if x != nil {
|
|
return x.User
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type UpdateUserRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
|
|
Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"`
|
|
Bio string `protobuf:"bytes,4,opt,name=bio,proto3" json:"bio,omitempty"`
|
|
AvatarUrl string `protobuf:"bytes,5,opt,name=avatar_url,json=avatarUrl,proto3" json:"avatar_url,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *UpdateUserRequest) Reset() {
|
|
*x = UpdateUserRequest{}
|
|
mi := &file_user_proto_msgTypes[5]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *UpdateUserRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*UpdateUserRequest) ProtoMessage() {}
|
|
|
|
func (x *UpdateUserRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[5]
|
|
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 UpdateUserRequest.ProtoReflect.Descriptor instead.
|
|
func (*UpdateUserRequest) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{5}
|
|
}
|
|
|
|
func (x *UpdateUserRequest) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateUserRequest) GetUsername() string {
|
|
if x != nil {
|
|
return x.Username
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateUserRequest) GetEmail() string {
|
|
if x != nil {
|
|
return x.Email
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateUserRequest) GetBio() string {
|
|
if x != nil {
|
|
return x.Bio
|
|
}
|
|
return ""
|
|
}
|
|
|
|
func (x *UpdateUserRequest) GetAvatarUrl() string {
|
|
if x != nil {
|
|
return x.AvatarUrl
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type UpdateUserResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
User *User `protobuf:"bytes,1,opt,name=user,proto3" json:"user,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *UpdateUserResponse) Reset() {
|
|
*x = UpdateUserResponse{}
|
|
mi := &file_user_proto_msgTypes[6]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *UpdateUserResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*UpdateUserResponse) ProtoMessage() {}
|
|
|
|
func (x *UpdateUserResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[6]
|
|
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 UpdateUserResponse.ProtoReflect.Descriptor instead.
|
|
func (*UpdateUserResponse) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{6}
|
|
}
|
|
|
|
func (x *UpdateUserResponse) GetUser() *User {
|
|
if x != nil {
|
|
return x.User
|
|
}
|
|
return nil
|
|
}
|
|
|
|
type DeleteUserRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *DeleteUserRequest) Reset() {
|
|
*x = DeleteUserRequest{}
|
|
mi := &file_user_proto_msgTypes[7]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *DeleteUserRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*DeleteUserRequest) ProtoMessage() {}
|
|
|
|
func (x *DeleteUserRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[7]
|
|
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 DeleteUserRequest.ProtoReflect.Descriptor instead.
|
|
func (*DeleteUserRequest) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{7}
|
|
}
|
|
|
|
func (x *DeleteUserRequest) GetId() string {
|
|
if x != nil {
|
|
return x.Id
|
|
}
|
|
return ""
|
|
}
|
|
|
|
type ListUsersRequest struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Page int32 `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty"`
|
|
PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListUsersRequest) Reset() {
|
|
*x = ListUsersRequest{}
|
|
mi := &file_user_proto_msgTypes[8]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListUsersRequest) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListUsersRequest) ProtoMessage() {}
|
|
|
|
func (x *ListUsersRequest) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[8]
|
|
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 ListUsersRequest.ProtoReflect.Descriptor instead.
|
|
func (*ListUsersRequest) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{8}
|
|
}
|
|
|
|
func (x *ListUsersRequest) GetPage() int32 {
|
|
if x != nil {
|
|
return x.Page
|
|
}
|
|
return 0
|
|
}
|
|
|
|
func (x *ListUsersRequest) GetPageSize() int32 {
|
|
if x != nil {
|
|
return x.PageSize
|
|
}
|
|
return 0
|
|
}
|
|
|
|
type ListUsersResponse struct {
|
|
state protoimpl.MessageState `protogen:"open.v1"`
|
|
Users []*User `protobuf:"bytes,1,rep,name=users,proto3" json:"users,omitempty"`
|
|
unknownFields protoimpl.UnknownFields
|
|
sizeCache protoimpl.SizeCache
|
|
}
|
|
|
|
func (x *ListUsersResponse) Reset() {
|
|
*x = ListUsersResponse{}
|
|
mi := &file_user_proto_msgTypes[9]
|
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
ms.StoreMessageInfo(mi)
|
|
}
|
|
|
|
func (x *ListUsersResponse) String() string {
|
|
return protoimpl.X.MessageStringOf(x)
|
|
}
|
|
|
|
func (*ListUsersResponse) ProtoMessage() {}
|
|
|
|
func (x *ListUsersResponse) ProtoReflect() protoreflect.Message {
|
|
mi := &file_user_proto_msgTypes[9]
|
|
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 ListUsersResponse.ProtoReflect.Descriptor instead.
|
|
func (*ListUsersResponse) Descriptor() ([]byte, []int) {
|
|
return file_user_proto_rawDescGZIP(), []int{9}
|
|
}
|
|
|
|
func (x *ListUsersResponse) GetUsers() []*User {
|
|
if x != nil {
|
|
return x.Users
|
|
}
|
|
return nil
|
|
}
|
|
|
|
var File_user_proto protoreflect.FileDescriptor
|
|
|
|
const file_user_proto_rawDesc = "" +
|
|
"\n" +
|
|
"\n" +
|
|
"user.proto\x12\x04user\x1a\x1bgoogle/protobuf/empty.proto\"\xb7\x01\n" +
|
|
"\x04User\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\x12\x1a\n" +
|
|
"\busername\x18\x02 \x01(\tR\busername\x12\x14\n" +
|
|
"\x05email\x18\x03 \x01(\tR\x05email\x12\x10\n" +
|
|
"\x03bio\x18\x04 \x01(\tR\x03bio\x12\x1d\n" +
|
|
"\n" +
|
|
"avatar_url\x18\x05 \x01(\tR\tavatarUrl\x12\x1d\n" +
|
|
"\n" +
|
|
"created_at\x18\x06 \x01(\x03R\tcreatedAt\x12\x1d\n" +
|
|
"\n" +
|
|
"updated_at\x18\a \x01(\x03R\tupdatedAt\"v\n" +
|
|
"\x11CreateUserRequest\x12\x1a\n" +
|
|
"\busername\x18\x01 \x01(\tR\busername\x12\x14\n" +
|
|
"\x05email\x18\x02 \x01(\tR\x05email\x12\x10\n" +
|
|
"\x03bio\x18\x03 \x01(\tR\x03bio\x12\x1d\n" +
|
|
"\n" +
|
|
"avatar_url\x18\x04 \x01(\tR\tavatarUrl\"4\n" +
|
|
"\x12CreateUserResponse\x12\x1e\n" +
|
|
"\x04user\x18\x01 \x01(\v2\n" +
|
|
".user.UserR\x04user\" \n" +
|
|
"\x0eGetUserRequest\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\"1\n" +
|
|
"\x0fGetUserResponse\x12\x1e\n" +
|
|
"\x04user\x18\x01 \x01(\v2\n" +
|
|
".user.UserR\x04user\"\x86\x01\n" +
|
|
"\x11UpdateUserRequest\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\x12\x1a\n" +
|
|
"\busername\x18\x02 \x01(\tR\busername\x12\x14\n" +
|
|
"\x05email\x18\x03 \x01(\tR\x05email\x12\x10\n" +
|
|
"\x03bio\x18\x04 \x01(\tR\x03bio\x12\x1d\n" +
|
|
"\n" +
|
|
"avatar_url\x18\x05 \x01(\tR\tavatarUrl\"4\n" +
|
|
"\x12UpdateUserResponse\x12\x1e\n" +
|
|
"\x04user\x18\x01 \x01(\v2\n" +
|
|
".user.UserR\x04user\"#\n" +
|
|
"\x11DeleteUserRequest\x12\x0e\n" +
|
|
"\x02id\x18\x01 \x01(\tR\x02id\"C\n" +
|
|
"\x10ListUsersRequest\x12\x12\n" +
|
|
"\x04page\x18\x01 \x01(\x05R\x04page\x12\x1b\n" +
|
|
"\tpage_size\x18\x02 \x01(\x05R\bpageSize\"5\n" +
|
|
"\x11ListUsersResponse\x12 \n" +
|
|
"\x05users\x18\x01 \x03(\v2\n" +
|
|
".user.UserR\x05users2\xc4\x02\n" +
|
|
"\vUserService\x12?\n" +
|
|
"\n" +
|
|
"CreateUser\x12\x17.user.CreateUserRequest\x1a\x18.user.CreateUserResponse\x126\n" +
|
|
"\aGetUser\x12\x14.user.GetUserRequest\x1a\x15.user.GetUserResponse\x12?\n" +
|
|
"\n" +
|
|
"UpdateUser\x12\x17.user.UpdateUserRequest\x1a\x18.user.UpdateUserResponse\x12=\n" +
|
|
"\n" +
|
|
"DeleteUser\x12\x17.user.DeleteUserRequest\x1a\x16.google.protobuf.Empty\x12<\n" +
|
|
"\tListUsers\x12\x16.user.ListUsersRequest\x1a\x17.user.ListUsersResponseB\x0eZ\f/user;userpbb\x06proto3"
|
|
|
|
var (
|
|
file_user_proto_rawDescOnce sync.Once
|
|
file_user_proto_rawDescData []byte
|
|
)
|
|
|
|
func file_user_proto_rawDescGZIP() []byte {
|
|
file_user_proto_rawDescOnce.Do(func() {
|
|
file_user_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_user_proto_rawDesc), len(file_user_proto_rawDesc)))
|
|
})
|
|
return file_user_proto_rawDescData
|
|
}
|
|
|
|
var file_user_proto_msgTypes = make([]protoimpl.MessageInfo, 10)
|
|
var file_user_proto_goTypes = []any{
|
|
(*User)(nil), // 0: user.User
|
|
(*CreateUserRequest)(nil), // 1: user.CreateUserRequest
|
|
(*CreateUserResponse)(nil), // 2: user.CreateUserResponse
|
|
(*GetUserRequest)(nil), // 3: user.GetUserRequest
|
|
(*GetUserResponse)(nil), // 4: user.GetUserResponse
|
|
(*UpdateUserRequest)(nil), // 5: user.UpdateUserRequest
|
|
(*UpdateUserResponse)(nil), // 6: user.UpdateUserResponse
|
|
(*DeleteUserRequest)(nil), // 7: user.DeleteUserRequest
|
|
(*ListUsersRequest)(nil), // 8: user.ListUsersRequest
|
|
(*ListUsersResponse)(nil), // 9: user.ListUsersResponse
|
|
(*emptypb.Empty)(nil), // 10: google.protobuf.Empty
|
|
}
|
|
var file_user_proto_depIdxs = []int32{
|
|
0, // 0: user.CreateUserResponse.user:type_name -> user.User
|
|
0, // 1: user.GetUserResponse.user:type_name -> user.User
|
|
0, // 2: user.UpdateUserResponse.user:type_name -> user.User
|
|
0, // 3: user.ListUsersResponse.users:type_name -> user.User
|
|
1, // 4: user.UserService.CreateUser:input_type -> user.CreateUserRequest
|
|
3, // 5: user.UserService.GetUser:input_type -> user.GetUserRequest
|
|
5, // 6: user.UserService.UpdateUser:input_type -> user.UpdateUserRequest
|
|
7, // 7: user.UserService.DeleteUser:input_type -> user.DeleteUserRequest
|
|
8, // 8: user.UserService.ListUsers:input_type -> user.ListUsersRequest
|
|
2, // 9: user.UserService.CreateUser:output_type -> user.CreateUserResponse
|
|
4, // 10: user.UserService.GetUser:output_type -> user.GetUserResponse
|
|
6, // 11: user.UserService.UpdateUser:output_type -> user.UpdateUserResponse
|
|
10, // 12: user.UserService.DeleteUser:output_type -> google.protobuf.Empty
|
|
9, // 13: user.UserService.ListUsers:output_type -> user.ListUsersResponse
|
|
9, // [9:14] is the sub-list for method output_type
|
|
4, // [4:9] is the sub-list for method input_type
|
|
4, // [4:4] is the sub-list for extension type_name
|
|
4, // [4:4] is the sub-list for extension extendee
|
|
0, // [0:4] is the sub-list for field type_name
|
|
}
|
|
|
|
func init() { file_user_proto_init() }
|
|
func file_user_proto_init() {
|
|
if File_user_proto != nil {
|
|
return
|
|
}
|
|
type x struct{}
|
|
out := protoimpl.TypeBuilder{
|
|
File: protoimpl.DescBuilder{
|
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
RawDescriptor: unsafe.Slice(unsafe.StringData(file_user_proto_rawDesc), len(file_user_proto_rawDesc)),
|
|
NumEnums: 0,
|
|
NumMessages: 10,
|
|
NumExtensions: 0,
|
|
NumServices: 1,
|
|
},
|
|
GoTypes: file_user_proto_goTypes,
|
|
DependencyIndexes: file_user_proto_depIdxs,
|
|
MessageInfos: file_user_proto_msgTypes,
|
|
}.Build()
|
|
File_user_proto = out.File
|
|
file_user_proto_goTypes = nil
|
|
file_user_proto_depIdxs = nil
|
|
}
|