1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
syntax = "proto3"; message Person { string name = 1; enum PhoneType { MOBILE = 0; HOME = 1; } oneof contact { string email = 3; string phone = 4; } } service AddressBook { rpc GetPerson(PersonRequest) returns (Person) { option idempotency_level = NO_SIDE_EFFECTS; } }