Skip to content

Instantly share code, notes, and snippets.

@LeoAdamek
Created June 26, 2018 11:01
Show Gist options
  • Save LeoAdamek/330647a6fcf90acbb2f08ae93d7a67ff to your computer and use it in GitHub Desktop.
Save LeoAdamek/330647a6fcf90acbb2f08ae93d7a67ff to your computer and use it in GitHub Desktop.
syntax = 'proto3';
package common;
message EntityRef {
string type = 1;
string id = 2;
}
syntax = 'proto3';
package sample;
import "common.proto";
service Sample {
rpc GetSample(GetSampleRequest) returns (GetSampleResponse) {}
}
message GetSampleRequest {
common.EntityRef entity = 1;
}
// Response just replies with the request for demo purposes.
message GetSampleResponse {
common.EntityRef entity = 1;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment