beteran-protobuf/proto/c2se/backend/member_class.proto
2022-08-12 08:52:46 +00:00

84 lines
2.0 KiB
Protocol Buffer

syntax = "proto3";
package bet.beteran.c2se.backend.member_class;
import "protobuf/rpc/error.proto";
import "protobuf/pagination/pagination.proto";
import "protobuf/pagination/search.proto";
import "protobuf/pagination/sort.proto";
import "models/member/member_class.proto";
// subject = bet.beteran.c2se.backend.member_class.CreateMemberClass
message CreateMemberClassRequest {
optional string parent_id = 1;
string name = 2;
}
message CreateMemberClassResponse {
message Result {
bet.beteran.member.MemberClass member_class = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.backend.member_class.ListMemberClasses
message ListMemberClassesRequest {
optional bet.protobuf.pagination.Pagination pagination = 1;
repeated bet.protobuf.pagination.Search searches = 2;
repeated bet.protobuf.pagination.Sort sorts = 3;
optional string name_like = 4;
}
message ListMemberClassesResponse {
message Result {
repeated bet.beteran.member.MemberClass member_classes = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.backend.member_class.GetMemberClass
message GetMemberClassRequest {
string id = 1;
}
message GetMemberClassResponse {
message Result {
bet.beteran.member.MemberClass member_class = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.backend.member_class.UpdateMemberClass
message UpdateMemberClassRequest {
string id = 1;
optional string parent_id = 2;
string name = 3;
}
message UpdateMemberClassResponse {
message Result {
bet.beteran.member.MemberClass member_class = 1;
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}
// subject = bet.beteran.c2se.backend.member_class.DeleteMemberClass
message DeleteMemberClassRequest {
string id = 1;
}
message DeleteMemberClassResponse {
message Result {
}
optional bet.protobuf.rpc.Error error = 1;
optional Result result = 2;
}