57 lines
921 B
Protocol Buffer
57 lines
921 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
import "users.proto";
|
|
|
|
option go_package = "git.itzana.me/strafesnet/go-grpc/ranks";
|
|
|
|
package ranks;
|
|
|
|
service RanksService {
|
|
rpc Get(GetRequest) returns (RankMessage);
|
|
rpc List(ListRequest) returns (RankList);
|
|
rpc Delete(IdMessage) returns (IdMessage);
|
|
}
|
|
|
|
message IdMessage {
|
|
int64 ID = 1;
|
|
}
|
|
|
|
message GetRequest {
|
|
int64 UserID = 1;
|
|
int32 StyleID = 2;
|
|
int32 GameID = 3;
|
|
int32 ModeID = 4;
|
|
}
|
|
|
|
message ListRequest {
|
|
int32 StyleID = 1;
|
|
int32 GameID = 2;
|
|
int32 ModeID = 3;
|
|
int64 Sort = 4;
|
|
repeated int32 StateID = 5;
|
|
Pagination Page = 6;
|
|
}
|
|
|
|
message RankList {
|
|
repeated RankMessage ranks = 1;
|
|
}
|
|
|
|
message RankMessage {
|
|
int64 ID = 1;
|
|
users.UserResponse User = 2;
|
|
int32 StyleID = 3;
|
|
int32 ModeID = 4;
|
|
int32 GameID = 5;
|
|
double Rank = 6;
|
|
double Skill = 7;
|
|
int64 UpdatedAt = 8;
|
|
}
|
|
|
|
message Pagination {
|
|
int32 Size = 1;
|
|
int32 Number = 2;
|
|
}
|
|
|
|
message NullResponse {
|
|
|
|
} |