JaiaBot 3.0.0
JaiaBot micro-AUV software
Loading...
Searching...
No Matches
rest_api.proto
Go to the documentation of this file.
1syntax = "proto2";
2
3import "jaiabot/messages/jaia_dccl.proto";
4import "jaiabot/messages/hub.proto";
5import "jaiabot/messages/metadata.proto";
6import "jaiabot/messages/option_extensions.proto";
7import "jaiabot/messages/mission.proto";
8import "jaiabot/messages/engineering.proto";
9import "jaiabot/messages/link.proto";
10
11package jaiabot.protobuf;
12
13message TaskPacketQuery
14{
15 optional uint64 start_time = 1
16 [(jaia.field).rest_api = {
17 doc: "Start of time range as a Unix timestamp in microseconds. If not set, returns an open-ended search, starting from the earliest available data."
18 }];
19 optional uint64 end_time = 2
20 [(jaia.field).rest_api = {
21 doc: "End of time range as a Unix timestamp in microseconds. If not set, returns an open-ended search, ending at the latest available data."
22 }];
23 repeated string mission_name = 4
24 [(jaia.field).rest_api = {
25 doc: "If set, only return task packets associated with the given mission name(s)."
26 }];
27 optional bool included_only = 3
28 [default = true, (jaia.field).rest_api = {
29 presence: GUARANTEED,
30 doc: "Whether to only return included (non-excluded) task packets."
31 }];
32 optional bool excluded_only = 5
33 [default = false, (jaia.field).rest_api = {
34 presence: GUARANTEED,
35 doc: "Whether to only return excluded task packets. Takes precedence over included_only."
36 }];
37 optional uint32 known_version = 6
38 [(jaia.field).rest_api = {
39 doc: "The version from an earlier response to this same query. If the task packets haven't changed since, the response has no packets and 'unchanged' is set. Only used with the JSON format."
40 }];
41 optional uint32 limit = 7
42 [default = 1000, (jaia.field).rest_api = {
43 presence: GUARANTEED,
44 doc: "Maximum number of task packets to return. When more match, the most recent are returned."
45 }];
46
47 enum Format {
48 JSON = 0 [(jaia.ev).rest_api = { presence: GUARANTEED }];
49 KMZ = 1 [(jaia.ev).rest_api = { presence: GUARANTEED }];
50 CSV = 2 [(jaia.ev).rest_api = { presence: GUARANTEED }];
51 GEOJSON_CONTOURS = 3 [(jaia.ev).rest_api = { presence: GUARANTEED }];
52 }
53
54 optional Format format = 16 [default = JSON, (jaia.field).rest_api.presence = GUARANTEED];
55}
56
57message TaskPacketQueryResults
58{
59 repeated TaskPacket packets = 1
60 [(jaia.field).rest_api.presence = GUARANTEED];
61 optional uint32 version = 2
62 [(jaia.field).rest_api = {
63 presence: GUARANTEED,
64 doc: "Version of the hub's task packets when this response was built. It changes whenever task packets are added, included or excluded."
65 }];
66 optional bool unchanged = 3
67 [(jaia.field).rest_api = {
68 doc: "Set when the request's known_version is still current, in which case packets is empty."
69 }];
70}
71
72message DepthContoursQuery
73{
74 repeated TaskPacket packets = 1
75 [(jaia.field).rest_api.presence = GUARANTEED];
76}
77
78message MissionQuery
79{
80 optional uint64 start_time = 1
81 [(jaia.field).rest_api = {
82 doc: "Start of time range as a Unix timestamp in microseconds. If not set, returns an open-ended search, starting from the earliest available data."
83 }];
84 optional uint64 end_time = 2
85 [(jaia.field).rest_api = {
86 doc: "End of time range as a Unix timestamp in microseconds. If not set, returns an open-ended search, ending at the latest available data."
87 }];
88}
89
90message MissionQueryResults
91{
92 repeated MissionSummary mission_summaries = 1
93 [(jaia.field).rest_api.presence = GUARANTEED];
94}
95
96
97message CommandResult
98{
99 required bool command_sent = 1
100 [(jaia.field).rest_api.presence = GUARANTEED];
101}
102
103message TaskPacketInclude {
104 required string task_packet_id = 1
105 [(jaia.field).rest_api.presence = GUARANTEED];
106 required bool include = 2
107 [(jaia.field).rest_api.presence = GUARANTEED];
108}
109
110message TaskPacketIncludeResponse {
111 required bool success = 1
112 [(jaia.field).rest_api.presence = GUARANTEED];
113}
114
115message RecordQuery {
116 // Implement a CRUD+L interface for exclusion zones and mission sets (Create, Read, Update, Delete, List)
117
118 enum RecordType {
119 EXCLUSION_ZONE = 1
120 [(jaia.ev).rest_api.presence = GUARANTEED];
121 MISSION_SET = 2
122 [(jaia.ev).rest_api.presence = GUARANTEED];
123 }
124
125 required RecordType type = 6
126 [(jaia.field).rest_api.presence = GUARANTEED];
127
128 optional bool list = 1 [(jaia.field).rest_api.presence = GUARANTEED];
129
130 optional string get_name = 2 [(jaia.field).rest_api.presence = GUARANTEED];
131
132 optional string delete_name = 3 [(jaia.field).rest_api.presence = GUARANTEED];
133
134 optional string save_name = 4 [(jaia.field).rest_api.presence = GUARANTEED];
135 optional string save_content = 5 [(jaia.field).rest_api.presence = GUARANTEED];
136}
137
138message RecordQueryResponse {
139 repeated string names = 1 [(jaia.field).rest_api.presence = GUARANTEED];
140 optional string content = 2 [(jaia.field).rest_api.presence = GUARANTEED];
141}
142
143
144enum APIErrorCode
145{
146 // REST API URL errors
147 API_ERROR__UNSUPPORTED_API_VERSION = 1
148 [(jaia.ev).rest_api.presence = GUARANTEED];
149 API_ERROR__INVALID_ACTION = 2 [(jaia.ev).rest_api.presence = GUARANTEED];
150 API_ERROR__TARGETS_STRING_MALFORMATTED = 3
151 [(jaia.ev).rest_api.presence = GUARANTEED];
152 API_ERROR__ACTION_REQUIRES_JSON_POST_DATA = 4
153 [(jaia.ev).rest_api.presence = GUARANTEED];
154 API_ERROR__INVALID_TARGET = 5 [(jaia.ev).rest_api.presence = GUARANTEED];
155
156 // Parse errors
157 API_ERROR__COULD_NOT_PARSE_API_REQUEST_JSON = 10
158 [(jaia.ev).rest_api.presence = GUARANTEED];
159
160 // Missing fields
161 API_ERROR__REQUEST_NOT_INITIALIZED = 11
162 [(jaia.ev).rest_api.presence = GUARANTEED];
163 API_ERROR__NO_ACTION_SPECIFIED = 12
164 [(jaia.ev).rest_api.presence = GUARANTEED];
165
166 API_ERROR__INVALID_TYPE = 13 [(jaia.ev).rest_api.presence = GUARANTEED];
167
168 // Unimplemented
169 API_ERROR__NOT_IMPLEMENTED = 20;
170
171 // Refused requests
172 API_ERROR__NOT_IN_CONTROL = 30 [(jaia.ev).rest_api.presence = GUARANTEED];
173 API_ERROR__RECORD_NOT_FOUND = 31 [(jaia.ev).rest_api.presence = GUARANTEED];
174 API_ERROR__INVALID_RECORD_NAME = 32 [(jaia.ev).rest_api.presence = GUARANTEED];
175
176 // A fault in the REST API itself
177 API_ERROR__INTERNAL_ERROR = 40 [(jaia.ev).rest_api.presence = GUARANTEED];
178}
179
180message APIError
181{
182 required APIErrorCode code = 1
183 [(jaia.field).rest_api.presence = GUARANTEED];
184 optional string details = 2 [(jaia.field).rest_api.presence = GUARANTEED];
185}
186
187message APIRequest
188{
189 message Nodes
190 {
191 repeated int32 hubs = 1 [(jaia.field).rest_api.presence = GUARANTEED];
192 repeated int32 bots = 2 [(jaia.field).rest_api.presence = GUARANTEED];
193 optional bool all = 3
194 [default = false, (jaia.field).rest_api.presence = GUARANTEED];
195 }
196 required Nodes target = 1 [(jaia.field).rest_api.presence = GUARANTEED];
197 // Authentication is Authelia's, in front of this API. Reserved rather than
198 // reused: a request from an older caller still carries the name.
199 reserved 2;
200 reserved "api_key";
201
202 oneof action
203 {
204 bool status = 11 [(jaia.field).rest_api = {
205 presence: GUARANTEED,
206 doc: "Query the status of bots/hubs. Expect a response of type 'status'."
207 example {
208 request: '{"status": true, "target": {"all": true}}'
209 response: '{"request":{"status":true,"target":{"all":true}},"status":{"bots":[{"attitude":{"course_over_ground":180.0,"heading":166.0,"pitch":85.0,"roll":-57.0},"battery_percent":95.0,"bot_id":1,"bot_type":"HYDRO","calibration_status":3,"depth":0.0,"hdop":0.25,"health_state":"HEALTH__OK","location":{"lat":41.657645,"lon":-71.27212},"mission_state":"PRE_DEPLOYMENT__IDLE","pdop":2.07,"received_time":"1722893284636801","salinity":20.0,"speed":{"over_ground":0.0},"temperature":15.06,"time":"1722878885000000","vcc_voltage":24.0,"wifi_link_quality_percentage":100},{"attitude":{"course_over_ground":180.0,"heading":166.0,"pitch":85.0,"roll":-57.0},"battery_percent":95.0,"bot_id":2,"bot_type":"HYDRO","calibration_status":3,"depth":0.0,"hdop":1.03,"health_state":"HEALTH__OK","location":{"lat":41.65765,"lon":-71.27212},"mission_state":"PRE_DEPLOYMENT__IDLE","pdop":1.47,"received_time":"1722893284635458","salinity":20.0,"speed":{"over_ground":0.0},"temperature":15.04,"time":"1722878885000000","vcc_voltage":24.0,"wifi_link_quality_percentage":100}],"hubs":[{"bot_ids_in_radio_file":[1,2],"fleet_id":0,"health_state":"HEALTH__OK","hub_id":1,"known_bot": [{"id": 1, "last_status_time": "1722893284000000"}, {"id": 2, "last_status_time": "1722893285000000"}],"linux_hardware_status":{"wifi":{"is_connected":true,"link_quality":70,"link_quality_percentage":100,"noise_level":0,"signal_level":33}},"location":{"lat":41.66268,"lon":-71.273018},"received_time":"1722893284552504","time":"8614394422756020"}]},"target":{"bots":[1,2],"hubs":[1]}}'
210 }
211 }];
212 bool metadata = 12 [(jaia.field).rest_api = {
213 presence: GUARANTEED,
214 doc: "Query the metadata of the hub. Expect a response of type 'metadata'."
215 example {
216 request: '{ "target": {"all": true },"metadata": true}'
217 response: '{"metadata": {"hubs": [{"goby_version": "3.1.5", "intervehicle_api_version": 7, "is_simulation": true, "ivp_version": "19.8.1+svn9395-10~ubuntu20.04.1", "jaiabot_image_build_date": "Thu Aug 15 16:20:53 UTC 2024", "jaiabot_image_first_boot_date": "Thu Aug 15 13:50:13 UTC 2024", "jaiabot_image_version": "1.12.0~beta2", "jaiabot_version": {"deb_release_branch": "1.y", "deb_repository": "beta", "major": "1", "minor": "12", "patch": "0~beta2"}, "moos_version": "10.4.0", "name": "hub2-fleet6", "raspi_firmware_version": "1.20220331", "xbee_node_id": "Not Available", "xbee_serial_number": "Not Available"}, {"goby_version": "3.1.5", "intervehicle_api_version": 7, "is_simulation": true, "ivp_version": "19.8.1+svn9395-10~ubuntu20.04.1", "jaiabot_image_build_date": "Thu Aug 15 16:20:53 UTC 2024", "jaiabot_image_first_boot_date": "Thu Aug 15 13:50:11 UTC 2024", "jaiabot_image_version": "1.12.0~beta2", "jaiabot_version": {"deb_release_branch": "1.y", "deb_repository": "beta", "major": "1", "minor": "12", "patch": "0~beta2"}, "moos_version": "10.4.0", "name": "hub1-fleet6", "raspi_firmware_version": "1.20220331", "xbee_node_id": "Not Available", "xbee_serial_number": "Not Available"}]}, "request": {"metadata": true, "target": {"all": true}}, "target": {"hubs": [2, 1]}}'
218 }
219 }];
220 TaskPacketQuery task_packets = 13 [(jaia.field).rest_api = {
221 presence: GUARANTEED,
222 doc: "Query task packets from a given range of time. Expect a response of type 'task_packets'."
223 example {
224 request: '{"target": {"bots": [1]}, "task_packets": {"start_time": 1722797666581176.0, "end_time": 1722970466581176.0}}'
225 response: '{"request": {"target": {"bots": [1]}, "task_packets": {"end_time": "1722970466581176", "start_time": "1722797666581176"}}, "task_packets": {"packets": [{"bot_id": 1, "drift": {"drift_duration": 10, "end_location": {"lat": 41.658228, "lon": -71.275736}, "estimated_drift": {"heading": 237.0, "speed": 0.9}, "significant_wave_height": 0.0, "start_location": {"lat": 41.658275, "lon": -71.275645}}, "end_time": "1722895675000000", "start_time": "1722895664000000", "type": "SURFACE_DRIFT"}, {"bot_id": 1, "drift": {"drift_duration": 10, "end_location": {"lat": 41.65826, "lon": -71.2757}, "estimated_drift": {"heading": 316.0, "speed": 0.6}, "significant_wave_height": 0.0, "start_location": {"lat": 41.658225, "lon": -71.275651}}, "end_time": "1722896712000000", "start_time": "1722896702000000", "type": "SURFACE_DRIFT"}, {"bot_id": 1, "drift": {"drift_duration": 10, "end_location": {"lat": 41.659469, "lon": -71.272064}, "estimated_drift": {"heading": 72.0, "speed": 0.7}, "significant_wave_height": 0.0, "start_location": {"lat": 41.659448, "lon": -71.272146}}, "end_time": "1722896904000000", "start_time": "1722896893000000", "type": "SURFACE_DRIFT"}], "version": 1593724481}}'
226 }
227 }];
228 MissionQuery missions = 16 [(jaia.field).rest_api = {
229 presence: GUARANTEED,
230 doc: "Query missions from a given range of time. Expect a response of type 'missions'."
231 example {
232 request: '{"target": {"all": true}, "missions": {"start_time": 1722797666581176.0, "end_time": 1722970466581176.0}}'
233 response: '{"missions": {"mission_summaries": [{"end_time": "1722896904000000", "mission_name": "mission1", "start_time": "1722895664000000", "task_packet_count": 3}]}, "request": {"missions": {"end_time": "1722970466581176", "start_time": "1722797666581176"}, "target": {"all": true}}, "target": {"hubs": [1], "bots": [1]}}'
234 }
235 }];
236 Command command = 14 [(jaia.field).rest_api = {
237 presence: GUARANTEED,
238 doc: "Send a command to one or more bots. Expect a response of type 'command_result'."
239 example {
240 request: '{"target": {"all": true}, "command": {"type": "STOP"}}'
241 response: '{"command_result": {"command_sent": true}, "request": {"command": {"bot_id": 1, "time": "1722895468966813", "type": "STOP"}, "target": {"all": true}}, "target": {"hubs": [1], "bots": [2, 1]}}'
242 }
243 }];
244 CommandForHub command_for_hub = 15 [(jaia.field).rest_api = {
245 presence: GUARANTEED,
246 doc: "Send a command to the hub. Expect a response of type 'command_result'."
247 example {
248 request: '{"target": {"all": true}, "command_for_hub": {"type": "SET_HUB_LOCATION", "hub_location": {"lat": 41.7, "lon": -70.3}}}'
249 response: '{"command_result": {"command_sent": true}, "request": {"command_for_hub": {"hub_id": 1, "hub_location": {"lat": 41.7, "lon": -70.3}, "time": "1722895686821358", "type": "SET_HUB_LOCATION"}, "target": {"all": true}}, "target": {"hubs": [1]}}'
250 }
251 }];
252 // Endpoints for JCC & JED
253 string take_control = 19 [(jaia.field).rest_api = {
254 presence: GUARANTEED,
255 doc: "The client ID of the operator who wants to take control. Expect a response of type 'controlling_client_id'."
256 example {
257 request: '{"target": {"all": true}, "take_control": "6CaPKsnbVhkLzq3jNXpgSU"}'
258 response: '{"controlling_client_id": "6CaPKsnbVhkLzq3jNXpgSU", "request": {"target": {"all": true}, "take_control": "6CaPKsnbVhkLzq3jNXpgSU"}}'
259 }
260 }];
261 Engineering engineering_command = 20 [(jaia.field).rest_api = {
262 presence: GUARANTEED,
263 doc: "Send an engineering command to bot(s). Expect a response of type 'command_result'."
264 example {
265 request: '{"target": {"bots": [1]}, "engineering_command": {"bot_id": 1, "query_engineering_status": true}}'
266 response: '{"target": {"hubs": [1, 2], "bots": [1]}, "command_result": {"command_sent": true}, "request": {"target": {"bots": [1]}, "engineering_command": {"bot_id": 1, "time": "1722895468966813", "query_engineering_status": true}}}'
267 }
268 }];
269 TaskPacketInclude task_packet_include = 21 [(jaia.field).rest_api = {
270 presence: GUARANTEED,
271 doc: "Include or exclude a task packet. Expect a response of type 'task_packet_include_response'."
272 example {
273 request: '{"target": {"all": true}, "task_packet_include": {"task_packet_id": "1_1722895664", "include": false}}'
274 response: '{"request": {"target": {"all": true}, "task_packet_include": {"task_packet_id": "1_1722895664", "include": false}}, "task_packet_include_response": {"success": true}}'
275 }
276 }];
277 bool download_ctd_profiles = 22 [(jaia.field).rest_api = {
278 presence: GUARANTEED,
279 doc: "Download the CTD profiles not yet downloaded from the hub as a zip file rather than an APIResponse. Responds with 204 No Content when there are none."
280 example {
281 request: '{"target": {"all": true}, "download_ctd_profiles": true}'
282 response: 'jaia-ctd.zip (application/zip) containing the not yet downloaded *.unb files from /var/log/jaiabot/bot_offload'
283 }
284 }];
285 RecordQuery record_query = 23 [(jaia.field).rest_api = {
286 presence: GUARANTEED,
287 doc: "List, get, save or delete the exclusion zones and mission sets stored on the hub. Expect a response of type 'record_query_response'."
288 example {
289 request: '{"target": {"all": true}, "record_query": {"type": "EXCLUSION_ZONE", "list": true}}'
290 response: '{"request": {"target": {"all": true}, "record_query": {"list": true, "type": "EXCLUSION_ZONE"}}, "record_query_response": {"names": ["harbor-entrance", "north-pier"]}}'
291 }
292 }];
293 DepthContoursQuery depth_contours = 24 [(jaia.field).rest_api = {
294 presence: GUARANTEED,
295 doc: "Generate depth contours from the given task packets. Responds with GeoJSON rather than an APIResponse."
296 example {
297 request: '{"target": {"all": true}, "depth_contours": {"packets": [{"bot_id": 1, "start_time": "1722895664000000", "end_time": "1722895700000000", "type": "DIVE", "dive": {"bottom_dive": true, "depth_achieved": 4.2, "start_location": {"lat": 41.658, "lon": -71.276}, "dive_rate": 0.5, "duration_to_acquire_gps": 8.0}}, {"bot_id": 1, "start_time": "1722895724000000", "end_time": "1722895760000000", "type": "DIVE", "dive": {"bottom_dive": true, "depth_achieved": 6.8, "start_location": {"lat": 41.6585, "lon": -71.275}, "dive_rate": 0.5, "duration_to_acquire_gps": 8.0}}, {"bot_id": 1, "start_time": "1722895784000000", "end_time": "1722895820000000", "type": "DIVE", "dive": {"bottom_dive": true, "depth_achieved": 9.5, "start_location": {"lat": 41.659, "lon": -71.2762}, "dive_rate": 0.5, "duration_to_acquire_gps": 8.0}}]}}'
298 response: '{"type": "FeatureCollection", "crs": {"type": "name", "properties": {"name": "EPSG:4326"}}, "features": [{"type": "Feature", "properties": {"type": "depth-contour", "value": 4.73, "fill": "#c9ebb1", "stroke-width": 0}, "geometry": {"type": "Polygon", "coordinates": [[[-71.276, 41.658], [-71.27602, 41.6581], [-71.275796, 41.658102], [-71.276, 41.658], [-71.276, 41.658]]]}}, {"type": "Feature", "properties": {"type": "depth-contour", "value": 4.73, "fill": "#c9ebb1", "stroke-width": 0}, "geometry": {"type": "Polygon", "coordinates": [[[-71.27602, 41.6581], [-71.27602, 41.6581], [-71.275796, 41.658102], [-71.275796, 41.658102], [-71.27602, 41.6581]]]}}]}'
299 }
300 }];
301 bool engineering_status = 25 [(jaia.field).rest_api = {
302 presence: GUARANTEED,
303 doc: "Query the most recent engineering status of bots. Expect a response of type 'engineering_status'."
304 example {
305 request: '{"target": {"bots": [1]}, "engineering_status": true}'
306 response: '{"target": {"bots": [1]}, "request": {"target": {"bots": [1]}, "engineering_status": true}, "engineering_status": {"bots": [{"bot_id": 1, "time": "1722895470000000", "pid_control": {"speed": {"Kp": 1.0, "Ki": 0.0, "Kd": 0.0}, "heading": {"Kp": 0.7, "Ki": 0.0, "Kd": 0.3}}, "bot_status_rate": "BotStatusRate_1_Hz", "gps_requirements": {"transit_hdop_req": 1.3, "transit_pdop_req": 2.2, "after_dive_hdop_req": 1.3, "after_dive_pdop_req": 2.2, "transit_gps_fix_checks": 5}, "rf_disable_options": {"rf_disable": false, "rf_disable_timeout_mins": 10}}]}}'
307 }
308 }];
309 }
310}
311
312
313// JCC's view of each node, built from a 'status' response rather than sent by the API
314
315message LinkStatusAge {
316 required Link link = 1;
317 required int32 age = 2;
318}
319
320message PortalBotStatus {
321 optional BotStatus bot_status = 1;
322 optional MissionPlan active_mission_plan = 2;
323 repeated LinkStatusAge active_link_status_age = 3;
324 optional int32 status_age = 4;
325 optional bool is_disconnected = 5;
326 optional Engineering engineering = 6;
327}
328
329message PortalHubStatus {
330 optional HubStatus hub_status = 1;
331 optional int32 status_age = 2;
332}
333
334
335message APIResponse
336{
337 message Nodes
338 {
339 repeated int32 hubs = 1 [(jaia.field).rest_api.presence = GUARANTEED];
340 repeated int32 bots = 2 [(jaia.field).rest_api.presence = GUARANTEED];
341 }
342 optional Nodes target = 1 [(jaia.field).rest_api.presence = GUARANTEED];
343 message Statuses
344 {
345 repeated BotStatus bots = 1
346 [(jaia.field).rest_api.presence = GUARANTEED];
347 repeated HubStatus hubs = 2
348 [(jaia.field).rest_api.presence = GUARANTEED];
349
350 message BotMissionPlan
351 {
352 required int32 bot_id = 1;
353 required MissionPlan mission_plan = 2;
354 }
355
356 repeated BotMissionPlan active_mission_plans = 4 [(jaia.field).rest_api = {
357 doc: "Mission plan currently active on each bot."
358 }];
359 optional string controlling_client_id = 5 [(jaia.field).rest_api = {
360 doc: "Client ID of the operator currently in control, or 'hubN' if an operator on another hub N sent the latest command."
361 }];
362 optional uint64 time = 6 [(jaia.field).rest_api = {
363 presence: GUARANTEED,
364 doc: "Hub's current time as a Unix timestamp in microseconds. Subtract received_time from this to get a status age that is independent of the client's clock."
365 }];
366 }
367
368 message EngineeringStatuses
369 {
370 repeated Engineering bots = 1
371 [(jaia.field).rest_api.presence = GUARANTEED];
372 }
373
374 message Metadatas
375 {
376 repeated DeviceMetadata hubs = 1
377 [(jaia.field).rest_api.presence = GUARANTEED];
378 }
379
380 oneof action
381 {
382 APIError error = 10 [(jaia.field).rest_api = {
383 presence: GUARANTEED,
384 doc: "Error with API Request. This can be sent in response to any failed Request action."
385 }];
386 Statuses status = 11 [(jaia.field).rest_api = {
387 presence: GUARANTEED,
388 doc: "Bot/Hub status. This is sent in response to a successful Request 'status' action."
389 }];
390 Metadatas metadata = 12 [(jaia.field).rest_api = {
391 presence: GUARANTEED,
392 doc: "Metadata response. This is sent in response to a successful Request 'metadata' action."
393 }];
394 TaskPacketQueryResults task_packets = 13 [(jaia.field).rest_api = {
395 presence: GUARANTEED,
396 doc: "Task packet response. This is sent in response to a successful Request 'task_packets' action."
397 }];
398 MissionQueryResults missions = 15 [(jaia.field).rest_api = {
399 presence: GUARANTEED,
400 doc: "Mission query response. This is sent in response to a successful Request 'missions' action."
401 }];
402 CommandResult command_result = 14 [(jaia.field).rest_api = {
403 presence: GUARANTEED,
404 doc: "Command result. This is sent in response to a successful Request 'command', 'command_for_hub' or 'engineering_command' action."
405 }];
406 string controlling_client_id = 18 [(jaia.field).rest_api = {
407 presence: GUARANTEED,
408 doc: "The client ID of the operator who has taken control."
409 }];
410 TaskPacketIncludeResponse task_packet_include_response = 21 [(jaia.field).rest_api = {
411 presence: GUARANTEED,
412 doc: "Response to a task packet include/exclude request."
413 }];
414 RecordQueryResponse record_query_response = 22 [(jaia.field).rest_api = {
415 presence: GUARANTEED,
416 doc: "Response related to exclusion zones and mission sets."
417 }];
418 EngineeringStatuses engineering_status = 23 [(jaia.field).rest_api = {
419 presence: GUARANTEED,
420 doc: "Most recent engineering status of each bot. This is sent in response to a successful Request 'engineering_status' action."
421 }];
422 }
423
424 // copy of original request
425 required APIRequest request = 20
426 [(jaia.field).rest_api = { presence: GUARANTEED }];
427}
428
429message APIConfig
430{
431 message StreamingEndpoint
432 {
433 required int32 hub_id = 1;
434 required string hostname = 2;
435 required int32 port = 3;
436 }
437
438 repeated StreamingEndpoint streaming_endpoint = 1;
439
440 optional int32 flask_bind_port = 2 [default = 9092];
441}