mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2025-11-05 17:40:24 +08:00
45 lines
677 B
Protocol Buffer
45 lines
677 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
option go_package = "./helloworld";
|
|
|
|
service Greeter {
|
|
rpc SayHello (HelloRequest) returns (HelloReply) {
|
|
}
|
|
}
|
|
|
|
message HelloRequest {
|
|
string name = 100;
|
|
int32 page_number = 101;
|
|
repeated int32 ages = 102;
|
|
}
|
|
|
|
message HelloReply {
|
|
string message = 1;
|
|
}
|
|
|
|
message SearchResult {
|
|
string query = 1;
|
|
int32 page_number = 2;
|
|
int32 result_per_page = 3;
|
|
|
|
enum Corpus {
|
|
option allow_alias = true;
|
|
|
|
UNIVERSAL = 0;
|
|
WEB = 1;
|
|
IMAGES = 2;
|
|
RUNNING = 2;
|
|
}
|
|
|
|
Corpus corpus = 4;
|
|
SearchResponse result = 5;
|
|
map<string, SearchResponse> resultMap = 6;
|
|
}
|
|
|
|
message SearchResponse {
|
|
reserved 1 to 15;
|
|
|
|
int32 count = 16;
|
|
bool isOk = 17;
|
|
bytes padding = 18;
|
|
} |