syntax = "proto3"; message Error { int32 code = 1; string message = 2; } message SubSubAMessage { string somestring = 1; } message SubSubBMessage { string somestring = 1; } message SubMessage { SubSubAMessage subsubmessageA = 1; repeated SubSubBMessage subsubmessageB = 2; } message Reply { enum Result { ERROR = 0; OK = 1; SOME_A = 2; } Result result = 1; Error error = 2; SubMessage submessage = 3; }