powerproto/examples/using-googleapis/apis/service.proto
storyicon 4f4006ee7d
chore(*): update plugin default options && add examples
Signed-off-by: storyicon <yuanchao@bilibili.com>
2021-07-28 11:57:21 +08:00

28 lines
587 B
Protocol Buffer

syntax = "proto3";
package powerproto.examples.using_googleapis;
option go_package = "github.com/storyicon/powerproto/examples/using_googleapis/apis;apis";
import "google/api/annotations.proto";
service Mocker {
rpc Echo (EchoRequest) returns (EchoResponse) {
option (google.api.http) = {
post: "/echo"
body: "*"
};
};
}
message EchoRequest {
string message = 1;
int64 timestamp = 2;
uint32 code = 3;
uint32 delay = 4;
}
message EchoResponse {
string message = 1;
int64 timestamp = 2;
string server = 3;
}