add all methods

This commit is contained in:
2025-05-17 02:57:29 +07:00
parent 282e1b3aea
commit 0e399d92eb
6 changed files with 1672 additions and 122 deletions
+64
View File
@@ -26,6 +26,18 @@ service EveningDetective {
};
}
rpc GetTeamsCSV(GetTeamsCSVReq) returns (GetTeamsCSVRsp) {
option (google.api.http) = {
get: "/csv"
};
}
rpc GetTeam(GetTeamReq) returns (GetTeamRsp) {
option (google.api.http) = {
get: "/teams/{id}"
};
}
rpc DeleteTeams(DeleteTeamsReq) returns (DeleteTeamsRsp) {
option (google.api.http) = {
delete: "/teams"
@@ -37,6 +49,27 @@ service EveningDetective {
post: "/actions"
};
}
rpc GameStart(GameStartReq) returns (GameStartRsp) {
option (google.api.http) = {
post: "/game/start",
body: "*"
};
}
rpc GameStop(GameStopReq) returns (GameStopRsp) {
option (google.api.http) = {
post: "/game/stop",
body: "*"
};
}
rpc GiveApplications(GiveApplicationsReq) returns (GiveApplicationsRsp) {
option (google.api.http) = {
post: "/teams/{teamId}/applications",
body: "*"
};
}
}
message PingReq {}
@@ -67,6 +100,12 @@ message GetTeamsRsp {
repeated TeamAdvanced teams = 1;
}
message GetTeamsCSVReq {}
message GetTeamsCSVRsp {
string data = 1;
}
message TeamAdvanced {
int64 id = 1;
string name = 2;
@@ -78,6 +117,14 @@ message Application {
string name = 1;
}
message GetTeamReq {
int64 id = 1;
}
message GetTeamRsp {
repeated AddActionRsp actions = 1;
}
message DeleteTeamsReq {}
message DeleteTeamsRsp {}
@@ -92,3 +139,20 @@ message AddActionRsp {
string text = 3;
repeated Application applications = 4;
}
message GameStartReq {}
message GameStartRsp {}
message GameStopReq {
int64 timeSeconds = 1;
}
message GameStopRsp {}
message GiveApplicationsReq {
int64 teamId = 1;
repeated Application applications = 2;
}
message GiveApplicationsRsp {}