66 lines
1.2 KiB
Protocol Buffer
66 lines
1.2 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package percutaneous;
|
|
option go_package="./percutaneous";
|
|
import "google/api/annotations.proto";
|
|
|
|
|
|
message WifiCheckRequest {
|
|
string host_code = 1;
|
|
}
|
|
|
|
message WifiSetRequest {
|
|
string host_code = 1;
|
|
}
|
|
|
|
message UseRequest {
|
|
string host_code = 1;
|
|
int64 user_id = 2;
|
|
string data = 3;
|
|
string stamp = 4;
|
|
int32 position = 5;
|
|
}
|
|
|
|
message UsedLogRequest {
|
|
int32 page = 1;
|
|
int32 size = 2;
|
|
}
|
|
|
|
message Response {
|
|
int32 code = 1;
|
|
string msg = 2;
|
|
string data = 3;
|
|
}
|
|
|
|
message WsStreamFrame {
|
|
bytes data = 1;
|
|
}
|
|
|
|
service Percutaneous {
|
|
rpc WifiCheck(WifiCheckRequest) returns (Response) {
|
|
option (google.api.http) = {
|
|
get: "/api/v3/percutaneous/wifi/check"
|
|
body: "*"
|
|
};
|
|
}
|
|
rpc WifiSet(WifiSetRequest) returns (Response) {
|
|
option (google.api.http) = {
|
|
post: "/api/v3/percutaneous/wifi/set"
|
|
body: "*"
|
|
};
|
|
}
|
|
rpc Use(UseRequest) returns (Response) {
|
|
option (google.api.http) = {
|
|
post: "/api/v3/percutaneous/use"
|
|
body: "*"
|
|
};
|
|
}
|
|
rpc UsedLog(UsedLogRequest) returns (Response) {
|
|
option (google.api.http) = {
|
|
get: "/api/v3/percutaneous/used/log"
|
|
body: "*"
|
|
};
|
|
}
|
|
rpc WsTunnelStream(stream WsStreamFrame) returns (stream Response);
|
|
}
|