github.com/grpc-ecosystem/grpc-gateway/v2@v2.19.1/examples/internal/proto/examplepb/wrappers.proto (about) 1 syntax = "proto3"; 2 3 package grpc.gateway.examples.internal.proto.examplepb; 4 5 import "google/api/annotations.proto"; 6 import "google/protobuf/empty.proto"; 7 import "google/protobuf/wrappers.proto"; 8 9 option go_package = "github.com/grpc-ecosystem/grpc-gateway/v2/examples/internal/proto/examplepb"; 10 11 message Wrappers { 12 google.protobuf.StringValue string_value = 1; 13 google.protobuf.Int32Value int32_value = 2; 14 google.protobuf.Int64Value int64_value = 3; 15 google.protobuf.FloatValue float_value = 4; 16 google.protobuf.DoubleValue double_value = 5; 17 google.protobuf.BoolValue bool_value = 6; 18 google.protobuf.UInt32Value uint32_value = 7; 19 google.protobuf.UInt64Value uint64_value = 8; 20 google.protobuf.BytesValue bytes_value = 9; 21 } 22 23 service WrappersService { 24 rpc Create(Wrappers) returns (Wrappers) { 25 option (google.api.http) = { 26 post: "/v1/example/wrappers" 27 body: "*" 28 }; 29 } 30 31 rpc CreateStringValue(google.protobuf.StringValue) returns (google.protobuf.StringValue) { 32 option (google.api.http) = { 33 post: "/v1/testString" 34 body: "*" 35 }; 36 } 37 rpc CreateInt32Value(google.protobuf.Int32Value) returns (google.protobuf.Int32Value) { 38 option (google.api.http) = { 39 post: "/v1/testInt32" 40 body: "*" 41 }; 42 } 43 rpc CreateInt64Value(google.protobuf.Int64Value) returns (google.protobuf.Int64Value) { 44 option (google.api.http) = { 45 post: "/v1/testInt64" 46 body: "*" 47 }; 48 } 49 rpc CreateFloatValue(google.protobuf.FloatValue) returns (google.protobuf.FloatValue) { 50 option (google.api.http) = { 51 post: "/v1/testFloat" 52 body: "*" 53 }; 54 } 55 rpc CreateDoubleValue(google.protobuf.DoubleValue) returns (google.protobuf.DoubleValue) { 56 option (google.api.http) = { 57 post: "/v1/testDouble" 58 body: "*" 59 }; 60 } 61 rpc CreateBoolValue(google.protobuf.BoolValue) returns (google.protobuf.BoolValue) { 62 option (google.api.http) = { 63 post: "/v1/testBool" 64 body: "*" 65 }; 66 } 67 rpc CreateUInt32Value(google.protobuf.UInt32Value) returns (google.protobuf.UInt32Value) { 68 option (google.api.http) = { 69 post: "/v1/testUint32" 70 body: "*" 71 }; 72 } 73 rpc CreateUInt64Value(google.protobuf.UInt64Value) returns (google.protobuf.UInt64Value) { 74 option (google.api.http) = { 75 post: "/v1/testUint64" 76 body: "*" 77 }; 78 } 79 rpc CreateBytesValue(google.protobuf.BytesValue) returns (google.protobuf.BytesValue) { 80 option (google.api.http) = { 81 post: "/v1/testBytes" 82 body: "*" 83 }; 84 } 85 rpc CreateEmpty(google.protobuf.Empty) returns (google.protobuf.Empty) { 86 option (google.api.http) = { 87 post: "/v1/testEmpty" 88 body: "*" 89 }; 90 } 91 }