This commit is contained in:
oneao committed 2025-11-28 22:41:37 +08:00
1 parent cf4291652a
commit 8408cf779f
20 files changed
+1400 -33

No files matched your search

@@ -0,0 +1,42 @@
syntax = "proto3";
package auth;
option go_package = "auth";
import "api.proto";
message LoginDefaultReq {
string Account = 1[(api.body)="account",(api.vd)="$!=''"];
string Password = 2[(api.body)="password",(api.vd)="$!=''"];
}
message LoginDefaultResp {
string token = 1;
string refreshToken = 2;
int64 userId = 3;
string username = 4;
int64 seqNo = 5;
int64 gender = 6;
}
message RegisterDefaultReq {
string Account = 1[(api.body)="account",(api.vd)="$!=''"];
string Password = 2[(api.body)="password",(api.vd)="$!=''"];
}
message RegisterDefaultResp {
}
service LoginService {
rpc LoginDefault(LoginDefaultReq) returns(LoginDefaultResp) {
option (api.post) = "/auth/login/default";
}
}
service RegisterService {
rpc RegisterDefault(RegisterDefaultReq) returns(RegisterDefaultResp) {
option (api.post) = "/auth/register/default";
}
}
@@ -1,6 +1,8 @@
syntax = "proto3";
option go_package = "auth";
package auth;
option go_package = "auth/login";
import "api.proto";
@@ -23,3 +25,4 @@ service LoginService {
option (api.post) = "/auth/login/default";
}
}
@@ -1,9 +1,12 @@
syntax = "proto3";
option go_package = "auth";
package auth;
option go_package = "auth/register";
import "api.proto";
message RegisterDefaultReq {
string Account = 1[(api.body)="account",(api.vd)="$!=''"];
string Password = 2[(api.body)="password",(api.vd)="$!=''"];