forked from openstf/STFService.apk
-
Notifications
You must be signed in to change notification settings - Fork 0
/
wire.proto
286 lines (231 loc) · 5.21 KB
/
wire.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
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
package jp.co.cyberagent.stf.proto;
option java_outer_classname = "Wire";
enum MessageType {
DO_IDENTIFY = 1;
DO_KEYEVENT = 2;
DO_TYPE = 3;
DO_WAKE = 4;
DO_ADD_ACCOUNT_MENU = 24;
DO_REMOVE_ACCOUNT = 20;
GET_ACCOUNTS = 26;
GET_BROWSERS = 5;
GET_CLIPBOARD = 6;
GET_DISPLAY = 19;
GET_PROPERTIES = 7;
GET_RINGER_MODE = 27;
GET_SD_STATUS = 25;
GET_VERSION = 8;
GET_WIFI_STATUS = 23;
SET_CLIPBOARD = 9;
SET_KEYGUARD_STATE = 10;
SET_RINGER_MODE = 21;
SET_ROTATION = 12;
SET_WAKE_LOCK = 11;
SET_WIFI_ENABLED = 22;
EVENT_AIRPLANE_MODE = 13;
EVENT_BATTERY = 14;
EVENT_CONNECTIVITY = 15;
EVENT_PHONE_STATE = 16;
EVENT_ROTATION = 17;
EVENT_BROWSER_PACKAGE = 18;
}
message Envelope {
optional uint32 id = 1;
required MessageType type = 2;
required bytes message = 3;
}
// Events
message AirplaneModeEvent {
required bool enabled = 1;
}
message BatteryEvent {
required string status = 1;
required string health = 2;
required string source = 3;
required uint32 level = 4;
required uint32 scale = 5;
required double temp = 6;
required double voltage = 7;
}
message BrowserApp {
required string name = 1;
required string component = 2;
required bool selected = 3;
required bool system = 4;
}
message BrowserPackageEvent {
required bool selected = 1;
repeated BrowserApp apps = 2;
}
message ConnectivityEvent {
required bool connected = 1;
optional string type = 2;
optional string subtype = 3;
optional bool failover = 4;
optional bool roaming = 5;
}
message PhoneStateEvent {
required string state = 1;
required bool manual = 2;
optional string operator = 3;
}
message RotationEvent {
required int32 rotation = 1;
}
// Service
message GetVersionRequest {
}
message GetVersionResponse {
required bool success = 1;
optional string version = 2;
}
message SetKeyguardStateRequest {
required bool enabled = 1;
}
message SetKeyguardStateResponse {
required bool success = 1;
}
message SetWakeLockRequest {
required bool enabled = 1;
}
message SetWakeLockResponse {
required bool success = 1;
}
enum ClipboardType {
TEXT = 1;
}
message SetClipboardRequest {
required ClipboardType type = 1;
optional string text = 2;
}
message SetClipboardResponse {
required bool success = 1;
}
message GetClipboardRequest {
required ClipboardType type = 1;
}
message GetClipboardResponse {
required bool success = 1;
optional ClipboardType type = 2;
optional string text = 3;
}
message GetBrowsersRequest {
}
message GetBrowsersResponse {
required bool success = 1;
required bool selected = 2;
repeated BrowserApp apps = 3;
}
message GetDisplayRequest {
required int32 id = 1;
}
message GetDisplayResponse {
required bool success = 1;
optional int32 width = 2;
optional int32 height = 3;
optional float xdpi = 4;
optional float ydpi = 5;
optional float fps = 6;
optional float density = 7;
optional int32 rotation = 8;
optional bool secure = 9;
}
message Property {
required string name = 1;
required string value = 2;
}
message GetPropertiesRequest {
repeated string properties = 1;
}
message GetPropertiesResponse {
required bool success = 1;
repeated Property properties = 2;
}
message DoIdentifyRequest {
required string serial = 1;
}
message DoIdentifyResponse {
required bool success = 1;
}
message GetAccountsRequest {
optional string type = 1;
}
message GetAccountsResponse {
required bool success = 1;
repeated string accounts = 2;
}
message DoAddAccountMenuRequest {
}
message DoAddAccountMenuResponse {
required bool success = 1;
}
message DoRemoveAccountRequest {
required string type = 1;
optional string account = 2;
}
message DoRemoveAccountResponse {
required bool success = 1;
}
enum RingerMode {
SILENT = 0;
VIBRATE = 1;
NORMAL = 2;
}
message SetRingerModeRequest {
required RingerMode mode = 1;
}
message SetRingerModeResponse {
required bool success = 1;
}
message GetRingerModeRequest {
}
message GetRingerModeResponse {
required bool success = 1;
required RingerMode mode = 2;
}
message SetWifiEnabledRequest {
required bool enabled = 1;
}
message SetWifiEnabledResponse {
required bool success = 1;
}
message GetWifiStatusRequest {
}
message GetWifiStatusResponse {
required bool success = 1;
required bool status = 2;
}
message GetSdStatusRequest {
}
message GetSdStatusResponse {
required bool success = 1;
required bool mounted = 2;
}
// Agent
enum KeyEvent {
DOWN = 0;
UP = 1;
PRESS = 2;
}
message KeyEventRequest {
required KeyEvent event = 1;
required int32 keyCode = 2;
optional bool shiftKey = 3;
optional bool ctrlKey = 4;
optional bool altKey = 5;
optional bool metaKey = 6;
optional bool symKey = 7;
optional bool functionKey = 8;
optional bool capsLockKey = 9;
optional bool scrollLockKey = 10;
optional bool numLockKey = 11;
}
message DoTypeRequest {
required string text = 1;
}
message SetRotationRequest {
required int32 rotation = 1;
required bool lock = 2;
}
message DoWakeRequest {
}