-
Notifications
You must be signed in to change notification settings - Fork 0
/
olapie_types_base.proto
170 lines (145 loc) · 2.63 KB
/
olapie_types_base.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
syntax = "proto3";
package types;
// protoc olapie_types_base.proto --go_out=.
// long name is to avoid conflicts with other file name
// same proto file names are not allowed in protocol buffer
option go_package = "go.olapie.com/types";
message Void {
}
message Point {
double x = 1;
double y = 2;
}
message Place {
string code = 1;
string name = 2;
Point coordinate = 3;
}
message Country {
string name = 1;
int64 calling_code = 2;
string flag = 3;
}
message Money {
string currency = 1;
string amount = 2;
}
message PhoneNumber {
int32 code = 1;
int64 number = 2;
string extension = 3;
}
message FullName {
string first = 1;
string middle = 2;
string last = 3;
}
enum Gender {
UNKNOWN = 0;
MALE = 1;
FEMALE = 2;
}
message PhotoID {
enum Type {
UNKNOWN = 0;
DRIVER_LICENSE = 1;
NATIONAL_ID = 2;
PASSPORT = 3;
}
Type type = 1;
string front = 2;
string back = 3;
string number = 4;
int64 issue_time = 5;
int64 expire_time = 6;
bool verified = 7;
}
message Education {
enum Degree {
UNKNOWN = 0;
PRIMARY_SCHOOL = 1;
JUNIOR_SCHOOL = 2;
HIGH_SCHOOL = 3;
JUNIOR_COLLEGE = 4;
BACHELOR = 5;
MASTER = 6;
PHD = 7;
}
Degree degree = 1;
string school = 2;
string major = 3;
int64 start_time = 4;
int64 end_time = 5;
Place place = 6;
bool verified = 7;
repeated string proofs = 8;
}
message Work {
string company = 1;
string title = 2;
int32 salary = 3;
int64 start_time = 4;
int64 end_time = 5;
Place place = 6;
bool verified = 7;
repeated string proofs = 8;
}
message Address {
string code = 1;
repeated string texts = 2;
string postal_code = 3;
}
message Image {
string url = 1;
int32 width = 2;
int32 height = 3;
string format = 4;
int32 size = 5;
string name = 6;
string thumbnail = 7;
bytes data = 8;
}
message Video {
string url = 1;
string format = 2;
int32 duration = 3;
int32 size = 4;
Image image = 5;
string name = 6;
bytes data = 7;
}
message Audio {
string url = 1;
string format = 2;
int32 duration = 3;
int32 size = 4;
string name = 5;
bytes data = 6;
}
message File {
string url = 1;
string name = 2;
int32 size = 3;
string format = 4;
bytes data = 5;
}
message WebPage {
string title = 1;
string summary = 2;
Image image = 3;
string url = 4;
}
message StringPair {
string v1 = 1;
string v2 = 2;
}
message UserProfile {
repeated PhotoID ids = 1;
repeated Image photos = 2;
repeated Video videos = 3;
repeated Work works = 4;
repeated Education educations = 5;
repeated File files = 6;
Address address = 7;
Place hometown = 8;
}