-
Notifications
You must be signed in to change notification settings - Fork 6
/
01-ajiting.proto
46 lines (37 loc) · 851 Bytes
/
01-ajiting.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
syntax = "proto3";
import "google/api/annotations.proto";
message Ajiting {
message GeoCoordinate {
string latitude = 1;
string longitude = 2;
}
string description = 1;
string url = 2;
GeoCoordinate location = 3;
repeated string free = 5;
}
message AjitingResponse {
Ajiting ajiting_message = 1;
}
message ListAjitingRequest {
string query = 1;
}
message ListAjitingResponse {
int32 num = 1;
repeated Ajiting ajitings = 2;
}
message UpdateAjitingRequest {
int32 id = 1;
Ajiting ajiting = 2;
}
service AjitingService {
rpc ListAjiting(ListAjitingRequest) returns (ListAjitingResponse) {
option (google.api.http).get = "/v1/ajiting";
}
rpc UpdateAjiting(UpdateAjitingRequest) returns (AjitingResponse) {
option (google.api.http) = {
put: "/v1/ajiting/{id}"
body: "ajiting"
};
}
}