-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathauth.proto
46 lines (37 loc) · 1.1 KB
/
auth.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
syntax = "proto3";
option csharp_namespace = "GsServer.Protobufs";
import "gs_protobufs/protos/custom_types/void_value.proto";
package protos.auth;
service AuthService {
rpc LoginAsync(LoginRequest) returns (LoginResponse);
rpc LogoutAsync(custom_types.void.VoidValue) returns (custom_types.void.VoidValue);
rpc RefreshTokenAsync(RefreshTokenRequest) returns (RefreshTokenResponse);
rpc RegisterAsync(RegisterRequest) returns (custom_types.void.VoidValue);
rpc NewPasswordAsync(NewPasswordRequest) returns (custom_types.void.VoidValue);
rpc ChangePasswordAsync(ChangePasswordRequest) returns (custom_types.void.VoidValue);
}
message LoginRequest {
string email = 1;
string password = 2;
}
message LoginResponse {
string access_token = 1;
string refresh_token = 2;
}
message RefreshTokenRequest {
string refresh_token = 1;
}
message RefreshTokenResponse {
string access_token = 1;
}
message RegisterRequest {
string email = 1;
string password = 2;
}
message NewPasswordRequest {
string email = 1;
}
message ChangePasswordRequest {
string old_password = 1;
string new_password = 2;
}