Simple v0.0.1
This commit is contained in:
48
proto/people.proto
Normal file
48
proto/people.proto
Normal file
@@ -0,0 +1,48 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package main;
|
||||
|
||||
option go_package = ".;main";
|
||||
|
||||
import "google/api/annotations.proto";
|
||||
|
||||
// The greeting service definition.
|
||||
service Name {
|
||||
// Sends a greeting
|
||||
rpc FirstName (NameRequest) returns (NameReply){
|
||||
option (google.api.http) = {
|
||||
post: "/v1/name/firstname"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
rpc LastName (NameRequest) returns (NameReply){
|
||||
option (google.api.http) = {
|
||||
post: "/v1/name/lastname"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
|
||||
rpc FullName (NameRequest) returns (NameReply){
|
||||
option (google.api.http) = {
|
||||
post: "/v1/name/fullname"
|
||||
body: "*"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
// The request message containing the user's name.
|
||||
message NameRequest {
|
||||
// NameType nametype = 1;
|
||||
}
|
||||
|
||||
// The response message containing the greetings
|
||||
message NameReply {
|
||||
string message = 1;
|
||||
}
|
||||
|
||||
// enum NameType {
|
||||
// FullName = 0;
|
||||
// FirstName = 1;
|
||||
// LastName = 2 ;
|
||||
// }
|
||||
Reference in New Issue
Block a user