Skip to content

Instantly share code, notes, and snippets.

@garystafford
Created July 3, 2021 13:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save garystafford/6d680c5d472bf474508c872fb1dc7d19 to your computer and use it in GitHub Desktop.
Save garystafford/6d680c5d472bf474508c872fb1dc7d19 to your computer and use it in GitHub Desktop.
syntax = "proto3";
package greeting.v3;
import "google/api/annotations.proto";
option go_package = "github.com/garystafford/pb-greeting/gen/go/greeting/v3";
message Greeting {
string id = 1;
string service = 2;
string message = 3;
string created = 4;
string hostname = 5;
}
message GreetingRequest {
Greeting greeting = 1;
}
message GreetingResponse {
repeated Greeting greeting = 1;
}
service GreetingService {
rpc Greeting (GreetingRequest) returns (GreetingResponse) {
option (google.api.http) = {
get: "/api/greeting"
};
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment