central_api_gateway/initialize/initialize.proto

41 lines
693 B
Protocol Buffer
Raw Normal View History

2017-05-20 08:01:21 +00:00
syntax = "proto3";
message AgentInfo {
string agentId = 1;
}
message InitResponse {
string secretKey = 1;
}
2017-06-06 07:36:07 +00:00
message ReqTempKeyInfo {
string apiKey = 1;
int64 localIp = 2;
string hostName = 3;
}
message TempKeyInfo {
string tempKey = 1;
double pollInterval = 2;
}
message TempKey {
string value = 1;
}
message AuthStatus {
enum AuthStatusType {
AUTH_WAIT = 0;
AUTH_ACCEPT = 1;
AUTH_REFUSE = 2;
}
AuthStatusType type = 1;
}
2017-05-20 08:01:21 +00:00
service Initializer {
2017-06-06 07:36:07 +00:00
rpc startAgent(AgentInfo) returns (InitResponse) {}
rpc requestTempKey(ReqTempKeyInfo) returns (TempKeyInfo) {}
rpc CheckAuth(TempKey) returns (AuthStatus) {}
2017-05-20 08:01:21 +00:00
}