add oauth proto file
All checks were successful
Publish / Publish Job (push) Successful in 2m30s

This commit is contained in:
Дмитрий
2026-04-23 10:46:34 +03:00
parent 28f8834c7b
commit 5847a6e560
4 changed files with 106 additions and 27 deletions

View File

@@ -14,9 +14,6 @@ service AuthService {
rpc GetSessions(GetSessionRequest) returns (GetSessionsResponse);
rpc TerminateSession(TerminateSessionRequest) returns (TerminateSessionResponse);
// === OAuth2 SSO ===
rpc GenerateOauthCode (GenerateOauthCodeRequest) returns (GenerateOauthCodeResponse);
rpc ExchangeOauthCode (ExchangeOauthCodeRequest) returns (ExchangeOauthCodeResponse);
// Системные методы для админа
rpc SystemCreateAccount (SystemCreateAccountRequest) returns (SystemCreateAccountResponse);
@@ -118,29 +115,6 @@ message TerminateSessionResponse {
}
// === Сообщения для OAuth2 SSO ===
message GenerateOauthCodeRequest {
string user_id = 1;
string client_id = 2;
string redirect_uri = 3;
}
message GenerateOauthCodeResponse {
string code = 1;
}
message ExchangeOauthCodeRequest {
string code = 1;
string client_id = 2;
string client_secret = 3;
}
message ExchangeOauthCodeResponse {
string access_token = 1;
int32 expires_in = 2;
}
message SystemCreateAccountRequest {
string username = 1;
string password_hash = 2; // Хеш пароля генерирует Admin Service и передает сюда