39 lines
674 B
Protocol Buffer
39 lines
674 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
package auth.v1;
|
|
|
|
service AuthService {
|
|
rpc SendOtp(SendOtpRequest) returns (SendOtpResponse);
|
|
rpc VerifyOtp(VerifyOtpRequest) returns (VerifyOtpResponse);
|
|
rpc Refresh(RefreshRequest) returns (RefreshResponse);
|
|
}
|
|
|
|
message SendOtpRequest {
|
|
string identifier = 1;
|
|
string type = 2;
|
|
}
|
|
|
|
message SendOtpResponse {
|
|
bool ok = 1;
|
|
}
|
|
|
|
|
|
message VerifyOtpRequest {
|
|
string identifier = 1;
|
|
string type = 2;
|
|
string code = 3;
|
|
}
|
|
|
|
message VerifyOtpResponse {
|
|
string access_token = 1;
|
|
string refresh_token = 2;
|
|
}
|
|
|
|
message RefreshRequest {
|
|
string refresh_token = 1;
|
|
}
|
|
message RefreshResponse {
|
|
string access_token = 1;
|
|
string refresh_token = 2;
|
|
}
|