ESPHome  2024.2.1
api_pb2_service.cpp
Go to the documentation of this file.
1 // This file was automatically generated with a tool.
2 // See scripts/api_protobuf/api_protobuf.py
3 #include "api_pb2_service.h"
4 #include "esphome/core/log.h"
5 
6 namespace esphome {
7 namespace api {
8 
9 static const char *const TAG = "api.service";
10 
12 #ifdef HAS_PROTO_MESSAGE_DUMP
13  ESP_LOGVV(TAG, "send_hello_response: %s", msg.dump().c_str());
14 #endif
15  return this->send_message_<HelloResponse>(msg, 2);
16 }
18 #ifdef HAS_PROTO_MESSAGE_DUMP
19  ESP_LOGVV(TAG, "send_connect_response: %s", msg.dump().c_str());
20 #endif
21  return this->send_message_<ConnectResponse>(msg, 4);
22 }
24 #ifdef HAS_PROTO_MESSAGE_DUMP
25  ESP_LOGVV(TAG, "send_disconnect_request: %s", msg.dump().c_str());
26 #endif
27  return this->send_message_<DisconnectRequest>(msg, 5);
28 }
30 #ifdef HAS_PROTO_MESSAGE_DUMP
31  ESP_LOGVV(TAG, "send_disconnect_response: %s", msg.dump().c_str());
32 #endif
33  return this->send_message_<DisconnectResponse>(msg, 6);
34 }
36 #ifdef HAS_PROTO_MESSAGE_DUMP
37  ESP_LOGVV(TAG, "send_ping_request: %s", msg.dump().c_str());
38 #endif
39  return this->send_message_<PingRequest>(msg, 7);
40 }
42 #ifdef HAS_PROTO_MESSAGE_DUMP
43  ESP_LOGVV(TAG, "send_ping_response: %s", msg.dump().c_str());
44 #endif
45  return this->send_message_<PingResponse>(msg, 8);
46 }
48 #ifdef HAS_PROTO_MESSAGE_DUMP
49  ESP_LOGVV(TAG, "send_device_info_response: %s", msg.dump().c_str());
50 #endif
51  return this->send_message_<DeviceInfoResponse>(msg, 10);
52 }
54 #ifdef HAS_PROTO_MESSAGE_DUMP
55  ESP_LOGVV(TAG, "send_list_entities_done_response: %s", msg.dump().c_str());
56 #endif
57  return this->send_message_<ListEntitiesDoneResponse>(msg, 19);
58 }
59 #ifdef USE_BINARY_SENSOR
61 #ifdef HAS_PROTO_MESSAGE_DUMP
62  ESP_LOGVV(TAG, "send_list_entities_binary_sensor_response: %s", msg.dump().c_str());
63 #endif
64  return this->send_message_<ListEntitiesBinarySensorResponse>(msg, 12);
65 }
66 #endif
67 #ifdef USE_BINARY_SENSOR
69 #ifdef HAS_PROTO_MESSAGE_DUMP
70  ESP_LOGVV(TAG, "send_binary_sensor_state_response: %s", msg.dump().c_str());
71 #endif
72  return this->send_message_<BinarySensorStateResponse>(msg, 21);
73 }
74 #endif
75 #ifdef USE_COVER
77 #ifdef HAS_PROTO_MESSAGE_DUMP
78  ESP_LOGVV(TAG, "send_list_entities_cover_response: %s", msg.dump().c_str());
79 #endif
80  return this->send_message_<ListEntitiesCoverResponse>(msg, 13);
81 }
82 #endif
83 #ifdef USE_COVER
85 #ifdef HAS_PROTO_MESSAGE_DUMP
86  ESP_LOGVV(TAG, "send_cover_state_response: %s", msg.dump().c_str());
87 #endif
88  return this->send_message_<CoverStateResponse>(msg, 22);
89 }
90 #endif
91 #ifdef USE_COVER
92 #endif
93 #ifdef USE_FAN
95 #ifdef HAS_PROTO_MESSAGE_DUMP
96  ESP_LOGVV(TAG, "send_list_entities_fan_response: %s", msg.dump().c_str());
97 #endif
98  return this->send_message_<ListEntitiesFanResponse>(msg, 14);
99 }
100 #endif
101 #ifdef USE_FAN
103 #ifdef HAS_PROTO_MESSAGE_DUMP
104  ESP_LOGVV(TAG, "send_fan_state_response: %s", msg.dump().c_str());
105 #endif
106  return this->send_message_<FanStateResponse>(msg, 23);
107 }
108 #endif
109 #ifdef USE_FAN
110 #endif
111 #ifdef USE_LIGHT
113 #ifdef HAS_PROTO_MESSAGE_DUMP
114  ESP_LOGVV(TAG, "send_list_entities_light_response: %s", msg.dump().c_str());
115 #endif
116  return this->send_message_<ListEntitiesLightResponse>(msg, 15);
117 }
118 #endif
119 #ifdef USE_LIGHT
121 #ifdef HAS_PROTO_MESSAGE_DUMP
122  ESP_LOGVV(TAG, "send_light_state_response: %s", msg.dump().c_str());
123 #endif
124  return this->send_message_<LightStateResponse>(msg, 24);
125 }
126 #endif
127 #ifdef USE_LIGHT
128 #endif
129 #ifdef USE_SENSOR
131 #ifdef HAS_PROTO_MESSAGE_DUMP
132  ESP_LOGVV(TAG, "send_list_entities_sensor_response: %s", msg.dump().c_str());
133 #endif
134  return this->send_message_<ListEntitiesSensorResponse>(msg, 16);
135 }
136 #endif
137 #ifdef USE_SENSOR
139 #ifdef HAS_PROTO_MESSAGE_DUMP
140  ESP_LOGVV(TAG, "send_sensor_state_response: %s", msg.dump().c_str());
141 #endif
142  return this->send_message_<SensorStateResponse>(msg, 25);
143 }
144 #endif
145 #ifdef USE_SWITCH
147 #ifdef HAS_PROTO_MESSAGE_DUMP
148  ESP_LOGVV(TAG, "send_list_entities_switch_response: %s", msg.dump().c_str());
149 #endif
150  return this->send_message_<ListEntitiesSwitchResponse>(msg, 17);
151 }
152 #endif
153 #ifdef USE_SWITCH
155 #ifdef HAS_PROTO_MESSAGE_DUMP
156  ESP_LOGVV(TAG, "send_switch_state_response: %s", msg.dump().c_str());
157 #endif
158  return this->send_message_<SwitchStateResponse>(msg, 26);
159 }
160 #endif
161 #ifdef USE_SWITCH
162 #endif
163 #ifdef USE_TEXT_SENSOR
165 #ifdef HAS_PROTO_MESSAGE_DUMP
166  ESP_LOGVV(TAG, "send_list_entities_text_sensor_response: %s", msg.dump().c_str());
167 #endif
168  return this->send_message_<ListEntitiesTextSensorResponse>(msg, 18);
169 }
170 #endif
171 #ifdef USE_TEXT_SENSOR
173 #ifdef HAS_PROTO_MESSAGE_DUMP
174  ESP_LOGVV(TAG, "send_text_sensor_state_response: %s", msg.dump().c_str());
175 #endif
176  return this->send_message_<TextSensorStateResponse>(msg, 27);
177 }
178 #endif
180  return this->send_message_<SubscribeLogsResponse>(msg, 29);
181 }
183 #ifdef HAS_PROTO_MESSAGE_DUMP
184  ESP_LOGVV(TAG, "send_homeassistant_service_response: %s", msg.dump().c_str());
185 #endif
186  return this->send_message_<HomeassistantServiceResponse>(msg, 35);
187 }
190 #ifdef HAS_PROTO_MESSAGE_DUMP
191  ESP_LOGVV(TAG, "send_subscribe_home_assistant_state_response: %s", msg.dump().c_str());
192 #endif
193  return this->send_message_<SubscribeHomeAssistantStateResponse>(msg, 39);
194 }
196 #ifdef HAS_PROTO_MESSAGE_DUMP
197  ESP_LOGVV(TAG, "send_get_time_request: %s", msg.dump().c_str());
198 #endif
199  return this->send_message_<GetTimeRequest>(msg, 36);
200 }
202 #ifdef HAS_PROTO_MESSAGE_DUMP
203  ESP_LOGVV(TAG, "send_get_time_response: %s", msg.dump().c_str());
204 #endif
205  return this->send_message_<GetTimeResponse>(msg, 37);
206 }
208 #ifdef HAS_PROTO_MESSAGE_DUMP
209  ESP_LOGVV(TAG, "send_list_entities_services_response: %s", msg.dump().c_str());
210 #endif
211  return this->send_message_<ListEntitiesServicesResponse>(msg, 41);
212 }
213 #ifdef USE_ESP32_CAMERA
215 #ifdef HAS_PROTO_MESSAGE_DUMP
216  ESP_LOGVV(TAG, "send_list_entities_camera_response: %s", msg.dump().c_str());
217 #endif
218  return this->send_message_<ListEntitiesCameraResponse>(msg, 43);
219 }
220 #endif
221 #ifdef USE_ESP32_CAMERA
223 #ifdef HAS_PROTO_MESSAGE_DUMP
224  ESP_LOGVV(TAG, "send_camera_image_response: %s", msg.dump().c_str());
225 #endif
226  return this->send_message_<CameraImageResponse>(msg, 44);
227 }
228 #endif
229 #ifdef USE_ESP32_CAMERA
230 #endif
231 #ifdef USE_CLIMATE
233 #ifdef HAS_PROTO_MESSAGE_DUMP
234  ESP_LOGVV(TAG, "send_list_entities_climate_response: %s", msg.dump().c_str());
235 #endif
236  return this->send_message_<ListEntitiesClimateResponse>(msg, 46);
237 }
238 #endif
239 #ifdef USE_CLIMATE
241 #ifdef HAS_PROTO_MESSAGE_DUMP
242  ESP_LOGVV(TAG, "send_climate_state_response: %s", msg.dump().c_str());
243 #endif
244  return this->send_message_<ClimateStateResponse>(msg, 47);
245 }
246 #endif
247 #ifdef USE_CLIMATE
248 #endif
249 #ifdef USE_NUMBER
251 #ifdef HAS_PROTO_MESSAGE_DUMP
252  ESP_LOGVV(TAG, "send_list_entities_number_response: %s", msg.dump().c_str());
253 #endif
254  return this->send_message_<ListEntitiesNumberResponse>(msg, 49);
255 }
256 #endif
257 #ifdef USE_NUMBER
259 #ifdef HAS_PROTO_MESSAGE_DUMP
260  ESP_LOGVV(TAG, "send_number_state_response: %s", msg.dump().c_str());
261 #endif
262  return this->send_message_<NumberStateResponse>(msg, 50);
263 }
264 #endif
265 #ifdef USE_NUMBER
266 #endif
267 #ifdef USE_SELECT
269 #ifdef HAS_PROTO_MESSAGE_DUMP
270  ESP_LOGVV(TAG, "send_list_entities_select_response: %s", msg.dump().c_str());
271 #endif
272  return this->send_message_<ListEntitiesSelectResponse>(msg, 52);
273 }
274 #endif
275 #ifdef USE_SELECT
277 #ifdef HAS_PROTO_MESSAGE_DUMP
278  ESP_LOGVV(TAG, "send_select_state_response: %s", msg.dump().c_str());
279 #endif
280  return this->send_message_<SelectStateResponse>(msg, 53);
281 }
282 #endif
283 #ifdef USE_SELECT
284 #endif
285 #ifdef USE_LOCK
287 #ifdef HAS_PROTO_MESSAGE_DUMP
288  ESP_LOGVV(TAG, "send_list_entities_lock_response: %s", msg.dump().c_str());
289 #endif
290  return this->send_message_<ListEntitiesLockResponse>(msg, 58);
291 }
292 #endif
293 #ifdef USE_LOCK
295 #ifdef HAS_PROTO_MESSAGE_DUMP
296  ESP_LOGVV(TAG, "send_lock_state_response: %s", msg.dump().c_str());
297 #endif
298  return this->send_message_<LockStateResponse>(msg, 59);
299 }
300 #endif
301 #ifdef USE_LOCK
302 #endif
303 #ifdef USE_BUTTON
305 #ifdef HAS_PROTO_MESSAGE_DUMP
306  ESP_LOGVV(TAG, "send_list_entities_button_response: %s", msg.dump().c_str());
307 #endif
308  return this->send_message_<ListEntitiesButtonResponse>(msg, 61);
309 }
310 #endif
311 #ifdef USE_BUTTON
312 #endif
313 #ifdef USE_MEDIA_PLAYER
315 #ifdef HAS_PROTO_MESSAGE_DUMP
316  ESP_LOGVV(TAG, "send_list_entities_media_player_response: %s", msg.dump().c_str());
317 #endif
318  return this->send_message_<ListEntitiesMediaPlayerResponse>(msg, 63);
319 }
320 #endif
321 #ifdef USE_MEDIA_PLAYER
323 #ifdef HAS_PROTO_MESSAGE_DUMP
324  ESP_LOGVV(TAG, "send_media_player_state_response: %s", msg.dump().c_str());
325 #endif
326  return this->send_message_<MediaPlayerStateResponse>(msg, 64);
327 }
328 #endif
329 #ifdef USE_MEDIA_PLAYER
330 #endif
331 #ifdef USE_BLUETOOTH_PROXY
332 #endif
333 #ifdef USE_BLUETOOTH_PROXY
335 #ifdef HAS_PROTO_MESSAGE_DUMP
336  ESP_LOGVV(TAG, "send_bluetooth_le_advertisement_response: %s", msg.dump().c_str());
337 #endif
338  return this->send_message_<BluetoothLEAdvertisementResponse>(msg, 67);
339 }
340 #endif
341 #ifdef USE_BLUETOOTH_PROXY
344 #ifdef HAS_PROTO_MESSAGE_DUMP
345  ESP_LOGVV(TAG, "send_bluetooth_le_raw_advertisements_response: %s", msg.dump().c_str());
346 #endif
347  return this->send_message_<BluetoothLERawAdvertisementsResponse>(msg, 93);
348 }
349 #endif
350 #ifdef USE_BLUETOOTH_PROXY
351 #endif
352 #ifdef USE_BLUETOOTH_PROXY
354 #ifdef HAS_PROTO_MESSAGE_DUMP
355  ESP_LOGVV(TAG, "send_bluetooth_device_connection_response: %s", msg.dump().c_str());
356 #endif
357  return this->send_message_<BluetoothDeviceConnectionResponse>(msg, 69);
358 }
359 #endif
360 #ifdef USE_BLUETOOTH_PROXY
361 #endif
362 #ifdef USE_BLUETOOTH_PROXY
364 #ifdef HAS_PROTO_MESSAGE_DUMP
365  ESP_LOGVV(TAG, "send_bluetooth_gatt_get_services_response: %s", msg.dump().c_str());
366 #endif
367  return this->send_message_<BluetoothGATTGetServicesResponse>(msg, 71);
368 }
369 #endif
370 #ifdef USE_BLUETOOTH_PROXY
373 #ifdef HAS_PROTO_MESSAGE_DUMP
374  ESP_LOGVV(TAG, "send_bluetooth_gatt_get_services_done_response: %s", msg.dump().c_str());
375 #endif
376  return this->send_message_<BluetoothGATTGetServicesDoneResponse>(msg, 72);
377 }
378 #endif
379 #ifdef USE_BLUETOOTH_PROXY
380 #endif
381 #ifdef USE_BLUETOOTH_PROXY
383 #ifdef HAS_PROTO_MESSAGE_DUMP
384  ESP_LOGVV(TAG, "send_bluetooth_gatt_read_response: %s", msg.dump().c_str());
385 #endif
386  return this->send_message_<BluetoothGATTReadResponse>(msg, 74);
387 }
388 #endif
389 #ifdef USE_BLUETOOTH_PROXY
390 #endif
391 #ifdef USE_BLUETOOTH_PROXY
392 #endif
393 #ifdef USE_BLUETOOTH_PROXY
394 #endif
395 #ifdef USE_BLUETOOTH_PROXY
396 #endif
397 #ifdef USE_BLUETOOTH_PROXY
399 #ifdef HAS_PROTO_MESSAGE_DUMP
400  ESP_LOGVV(TAG, "send_bluetooth_gatt_notify_data_response: %s", msg.dump().c_str());
401 #endif
402  return this->send_message_<BluetoothGATTNotifyDataResponse>(msg, 79);
403 }
404 #endif
405 #ifdef USE_BLUETOOTH_PROXY
406 #endif
407 #ifdef USE_BLUETOOTH_PROXY
409 #ifdef HAS_PROTO_MESSAGE_DUMP
410  ESP_LOGVV(TAG, "send_bluetooth_connections_free_response: %s", msg.dump().c_str());
411 #endif
412  return this->send_message_<BluetoothConnectionsFreeResponse>(msg, 81);
413 }
414 #endif
415 #ifdef USE_BLUETOOTH_PROXY
417 #ifdef HAS_PROTO_MESSAGE_DUMP
418  ESP_LOGVV(TAG, "send_bluetooth_gatt_error_response: %s", msg.dump().c_str());
419 #endif
420  return this->send_message_<BluetoothGATTErrorResponse>(msg, 82);
421 }
422 #endif
423 #ifdef USE_BLUETOOTH_PROXY
425 #ifdef HAS_PROTO_MESSAGE_DUMP
426  ESP_LOGVV(TAG, "send_bluetooth_gatt_write_response: %s", msg.dump().c_str());
427 #endif
428  return this->send_message_<BluetoothGATTWriteResponse>(msg, 83);
429 }
430 #endif
431 #ifdef USE_BLUETOOTH_PROXY
433 #ifdef HAS_PROTO_MESSAGE_DUMP
434  ESP_LOGVV(TAG, "send_bluetooth_gatt_notify_response: %s", msg.dump().c_str());
435 #endif
436  return this->send_message_<BluetoothGATTNotifyResponse>(msg, 84);
437 }
438 #endif
439 #ifdef USE_BLUETOOTH_PROXY
441 #ifdef HAS_PROTO_MESSAGE_DUMP
442  ESP_LOGVV(TAG, "send_bluetooth_device_pairing_response: %s", msg.dump().c_str());
443 #endif
444  return this->send_message_<BluetoothDevicePairingResponse>(msg, 85);
445 }
446 #endif
447 #ifdef USE_BLUETOOTH_PROXY
449 #ifdef HAS_PROTO_MESSAGE_DUMP
450  ESP_LOGVV(TAG, "send_bluetooth_device_unpairing_response: %s", msg.dump().c_str());
451 #endif
452  return this->send_message_<BluetoothDeviceUnpairingResponse>(msg, 86);
453 }
454 #endif
455 #ifdef USE_BLUETOOTH_PROXY
456 #endif
457 #ifdef USE_BLUETOOTH_PROXY
459 #ifdef HAS_PROTO_MESSAGE_DUMP
460  ESP_LOGVV(TAG, "send_bluetooth_device_clear_cache_response: %s", msg.dump().c_str());
461 #endif
462  return this->send_message_<BluetoothDeviceClearCacheResponse>(msg, 88);
463 }
464 #endif
465 #ifdef USE_VOICE_ASSISTANT
466 #endif
467 #ifdef USE_VOICE_ASSISTANT
469 #ifdef HAS_PROTO_MESSAGE_DUMP
470  ESP_LOGVV(TAG, "send_voice_assistant_request: %s", msg.dump().c_str());
471 #endif
472  return this->send_message_<VoiceAssistantRequest>(msg, 90);
473 }
474 #endif
475 #ifdef USE_VOICE_ASSISTANT
476 #endif
477 #ifdef USE_VOICE_ASSISTANT
478 #endif
479 #ifdef USE_ALARM_CONTROL_PANEL
482 #ifdef HAS_PROTO_MESSAGE_DUMP
483  ESP_LOGVV(TAG, "send_list_entities_alarm_control_panel_response: %s", msg.dump().c_str());
484 #endif
485  return this->send_message_<ListEntitiesAlarmControlPanelResponse>(msg, 94);
486 }
487 #endif
488 #ifdef USE_ALARM_CONTROL_PANEL
490 #ifdef HAS_PROTO_MESSAGE_DUMP
491  ESP_LOGVV(TAG, "send_alarm_control_panel_state_response: %s", msg.dump().c_str());
492 #endif
493  return this->send_message_<AlarmControlPanelStateResponse>(msg, 95);
494 }
495 #endif
496 #ifdef USE_ALARM_CONTROL_PANEL
497 #endif
498 #ifdef USE_TEXT
500 #ifdef HAS_PROTO_MESSAGE_DUMP
501  ESP_LOGVV(TAG, "send_list_entities_text_response: %s", msg.dump().c_str());
502 #endif
503  return this->send_message_<ListEntitiesTextResponse>(msg, 97);
504 }
505 #endif
506 #ifdef USE_TEXT
508 #ifdef HAS_PROTO_MESSAGE_DUMP
509  ESP_LOGVV(TAG, "send_text_state_response: %s", msg.dump().c_str());
510 #endif
511  return this->send_message_<TextStateResponse>(msg, 98);
512 }
513 #endif
514 #ifdef USE_TEXT
515 #endif
516 bool APIServerConnectionBase::read_message(uint32_t msg_size, uint32_t msg_type, uint8_t *msg_data) {
517  switch (msg_type) {
518  case 1: {
519  HelloRequest msg;
520  msg.decode(msg_data, msg_size);
521 #ifdef HAS_PROTO_MESSAGE_DUMP
522  ESP_LOGVV(TAG, "on_hello_request: %s", msg.dump().c_str());
523 #endif
524  this->on_hello_request(msg);
525  break;
526  }
527  case 3: {
528  ConnectRequest msg;
529  msg.decode(msg_data, msg_size);
530 #ifdef HAS_PROTO_MESSAGE_DUMP
531  ESP_LOGVV(TAG, "on_connect_request: %s", msg.dump().c_str());
532 #endif
533  this->on_connect_request(msg);
534  break;
535  }
536  case 5: {
537  DisconnectRequest msg;
538  msg.decode(msg_data, msg_size);
539 #ifdef HAS_PROTO_MESSAGE_DUMP
540  ESP_LOGVV(TAG, "on_disconnect_request: %s", msg.dump().c_str());
541 #endif
542  this->on_disconnect_request(msg);
543  break;
544  }
545  case 6: {
546  DisconnectResponse msg;
547  msg.decode(msg_data, msg_size);
548 #ifdef HAS_PROTO_MESSAGE_DUMP
549  ESP_LOGVV(TAG, "on_disconnect_response: %s", msg.dump().c_str());
550 #endif
551  this->on_disconnect_response(msg);
552  break;
553  }
554  case 7: {
555  PingRequest msg;
556  msg.decode(msg_data, msg_size);
557 #ifdef HAS_PROTO_MESSAGE_DUMP
558  ESP_LOGVV(TAG, "on_ping_request: %s", msg.dump().c_str());
559 #endif
560  this->on_ping_request(msg);
561  break;
562  }
563  case 8: {
564  PingResponse msg;
565  msg.decode(msg_data, msg_size);
566 #ifdef HAS_PROTO_MESSAGE_DUMP
567  ESP_LOGVV(TAG, "on_ping_response: %s", msg.dump().c_str());
568 #endif
569  this->on_ping_response(msg);
570  break;
571  }
572  case 9: {
573  DeviceInfoRequest msg;
574  msg.decode(msg_data, msg_size);
575 #ifdef HAS_PROTO_MESSAGE_DUMP
576  ESP_LOGVV(TAG, "on_device_info_request: %s", msg.dump().c_str());
577 #endif
578  this->on_device_info_request(msg);
579  break;
580  }
581  case 11: {
583  msg.decode(msg_data, msg_size);
584 #ifdef HAS_PROTO_MESSAGE_DUMP
585  ESP_LOGVV(TAG, "on_list_entities_request: %s", msg.dump().c_str());
586 #endif
587  this->on_list_entities_request(msg);
588  break;
589  }
590  case 20: {
592  msg.decode(msg_data, msg_size);
593 #ifdef HAS_PROTO_MESSAGE_DUMP
594  ESP_LOGVV(TAG, "on_subscribe_states_request: %s", msg.dump().c_str());
595 #endif
596  this->on_subscribe_states_request(msg);
597  break;
598  }
599  case 28: {
601  msg.decode(msg_data, msg_size);
602 #ifdef HAS_PROTO_MESSAGE_DUMP
603  ESP_LOGVV(TAG, "on_subscribe_logs_request: %s", msg.dump().c_str());
604 #endif
605  this->on_subscribe_logs_request(msg);
606  break;
607  }
608  case 30: {
609 #ifdef USE_COVER
611  msg.decode(msg_data, msg_size);
612 #ifdef HAS_PROTO_MESSAGE_DUMP
613  ESP_LOGVV(TAG, "on_cover_command_request: %s", msg.dump().c_str());
614 #endif
615  this->on_cover_command_request(msg);
616 #endif
617  break;
618  }
619  case 31: {
620 #ifdef USE_FAN
621  FanCommandRequest msg;
622  msg.decode(msg_data, msg_size);
623 #ifdef HAS_PROTO_MESSAGE_DUMP
624  ESP_LOGVV(TAG, "on_fan_command_request: %s", msg.dump().c_str());
625 #endif
626  this->on_fan_command_request(msg);
627 #endif
628  break;
629  }
630  case 32: {
631 #ifdef USE_LIGHT
633  msg.decode(msg_data, msg_size);
634 #ifdef HAS_PROTO_MESSAGE_DUMP
635  ESP_LOGVV(TAG, "on_light_command_request: %s", msg.dump().c_str());
636 #endif
637  this->on_light_command_request(msg);
638 #endif
639  break;
640  }
641  case 33: {
642 #ifdef USE_SWITCH
644  msg.decode(msg_data, msg_size);
645 #ifdef HAS_PROTO_MESSAGE_DUMP
646  ESP_LOGVV(TAG, "on_switch_command_request: %s", msg.dump().c_str());
647 #endif
648  this->on_switch_command_request(msg);
649 #endif
650  break;
651  }
652  case 34: {
654  msg.decode(msg_data, msg_size);
655 #ifdef HAS_PROTO_MESSAGE_DUMP
656  ESP_LOGVV(TAG, "on_subscribe_homeassistant_services_request: %s", msg.dump().c_str());
657 #endif
659  break;
660  }
661  case 36: {
662  GetTimeRequest msg;
663  msg.decode(msg_data, msg_size);
664 #ifdef HAS_PROTO_MESSAGE_DUMP
665  ESP_LOGVV(TAG, "on_get_time_request: %s", msg.dump().c_str());
666 #endif
667  this->on_get_time_request(msg);
668  break;
669  }
670  case 37: {
671  GetTimeResponse msg;
672  msg.decode(msg_data, msg_size);
673 #ifdef HAS_PROTO_MESSAGE_DUMP
674  ESP_LOGVV(TAG, "on_get_time_response: %s", msg.dump().c_str());
675 #endif
676  this->on_get_time_response(msg);
677  break;
678  }
679  case 38: {
681  msg.decode(msg_data, msg_size);
682 #ifdef HAS_PROTO_MESSAGE_DUMP
683  ESP_LOGVV(TAG, "on_subscribe_home_assistant_states_request: %s", msg.dump().c_str());
684 #endif
686  break;
687  }
688  case 40: {
690  msg.decode(msg_data, msg_size);
691 #ifdef HAS_PROTO_MESSAGE_DUMP
692  ESP_LOGVV(TAG, "on_home_assistant_state_response: %s", msg.dump().c_str());
693 #endif
695  break;
696  }
697  case 42: {
699  msg.decode(msg_data, msg_size);
700 #ifdef HAS_PROTO_MESSAGE_DUMP
701  ESP_LOGVV(TAG, "on_execute_service_request: %s", msg.dump().c_str());
702 #endif
703  this->on_execute_service_request(msg);
704  break;
705  }
706  case 45: {
707 #ifdef USE_ESP32_CAMERA
708  CameraImageRequest msg;
709  msg.decode(msg_data, msg_size);
710 #ifdef HAS_PROTO_MESSAGE_DUMP
711  ESP_LOGVV(TAG, "on_camera_image_request: %s", msg.dump().c_str());
712 #endif
713  this->on_camera_image_request(msg);
714 #endif
715  break;
716  }
717  case 48: {
718 #ifdef USE_CLIMATE
720  msg.decode(msg_data, msg_size);
721 #ifdef HAS_PROTO_MESSAGE_DUMP
722  ESP_LOGVV(TAG, "on_climate_command_request: %s", msg.dump().c_str());
723 #endif
724  this->on_climate_command_request(msg);
725 #endif
726  break;
727  }
728  case 51: {
729 #ifdef USE_NUMBER
731  msg.decode(msg_data, msg_size);
732 #ifdef HAS_PROTO_MESSAGE_DUMP
733  ESP_LOGVV(TAG, "on_number_command_request: %s", msg.dump().c_str());
734 #endif
735  this->on_number_command_request(msg);
736 #endif
737  break;
738  }
739  case 54: {
740 #ifdef USE_SELECT
742  msg.decode(msg_data, msg_size);
743 #ifdef HAS_PROTO_MESSAGE_DUMP
744  ESP_LOGVV(TAG, "on_select_command_request: %s", msg.dump().c_str());
745 #endif
746  this->on_select_command_request(msg);
747 #endif
748  break;
749  }
750  case 60: {
751 #ifdef USE_LOCK
752  LockCommandRequest msg;
753  msg.decode(msg_data, msg_size);
754 #ifdef HAS_PROTO_MESSAGE_DUMP
755  ESP_LOGVV(TAG, "on_lock_command_request: %s", msg.dump().c_str());
756 #endif
757  this->on_lock_command_request(msg);
758 #endif
759  break;
760  }
761  case 62: {
762 #ifdef USE_BUTTON
764  msg.decode(msg_data, msg_size);
765 #ifdef HAS_PROTO_MESSAGE_DUMP
766  ESP_LOGVV(TAG, "on_button_command_request: %s", msg.dump().c_str());
767 #endif
768  this->on_button_command_request(msg);
769 #endif
770  break;
771  }
772  case 65: {
773 #ifdef USE_MEDIA_PLAYER
775  msg.decode(msg_data, msg_size);
776 #ifdef HAS_PROTO_MESSAGE_DUMP
777  ESP_LOGVV(TAG, "on_media_player_command_request: %s", msg.dump().c_str());
778 #endif
780 #endif
781  break;
782  }
783  case 66: {
784 #ifdef USE_BLUETOOTH_PROXY
786  msg.decode(msg_data, msg_size);
787 #ifdef HAS_PROTO_MESSAGE_DUMP
788  ESP_LOGVV(TAG, "on_subscribe_bluetooth_le_advertisements_request: %s", msg.dump().c_str());
789 #endif
791 #endif
792  break;
793  }
794  case 68: {
795 #ifdef USE_BLUETOOTH_PROXY
797  msg.decode(msg_data, msg_size);
798 #ifdef HAS_PROTO_MESSAGE_DUMP
799  ESP_LOGVV(TAG, "on_bluetooth_device_request: %s", msg.dump().c_str());
800 #endif
801  this->on_bluetooth_device_request(msg);
802 #endif
803  break;
804  }
805  case 70: {
806 #ifdef USE_BLUETOOTH_PROXY
808  msg.decode(msg_data, msg_size);
809 #ifdef HAS_PROTO_MESSAGE_DUMP
810  ESP_LOGVV(TAG, "on_bluetooth_gatt_get_services_request: %s", msg.dump().c_str());
811 #endif
813 #endif
814  break;
815  }
816  case 73: {
817 #ifdef USE_BLUETOOTH_PROXY
819  msg.decode(msg_data, msg_size);
820 #ifdef HAS_PROTO_MESSAGE_DUMP
821  ESP_LOGVV(TAG, "on_bluetooth_gatt_read_request: %s", msg.dump().c_str());
822 #endif
824 #endif
825  break;
826  }
827  case 75: {
828 #ifdef USE_BLUETOOTH_PROXY
830  msg.decode(msg_data, msg_size);
831 #ifdef HAS_PROTO_MESSAGE_DUMP
832  ESP_LOGVV(TAG, "on_bluetooth_gatt_write_request: %s", msg.dump().c_str());
833 #endif
835 #endif
836  break;
837  }
838  case 76: {
839 #ifdef USE_BLUETOOTH_PROXY
841  msg.decode(msg_data, msg_size);
842 #ifdef HAS_PROTO_MESSAGE_DUMP
843  ESP_LOGVV(TAG, "on_bluetooth_gatt_read_descriptor_request: %s", msg.dump().c_str());
844 #endif
846 #endif
847  break;
848  }
849  case 77: {
850 #ifdef USE_BLUETOOTH_PROXY
852  msg.decode(msg_data, msg_size);
853 #ifdef HAS_PROTO_MESSAGE_DUMP
854  ESP_LOGVV(TAG, "on_bluetooth_gatt_write_descriptor_request: %s", msg.dump().c_str());
855 #endif
857 #endif
858  break;
859  }
860  case 78: {
861 #ifdef USE_BLUETOOTH_PROXY
863  msg.decode(msg_data, msg_size);
864 #ifdef HAS_PROTO_MESSAGE_DUMP
865  ESP_LOGVV(TAG, "on_bluetooth_gatt_notify_request: %s", msg.dump().c_str());
866 #endif
868 #endif
869  break;
870  }
871  case 80: {
872 #ifdef USE_BLUETOOTH_PROXY
874  msg.decode(msg_data, msg_size);
875 #ifdef HAS_PROTO_MESSAGE_DUMP
876  ESP_LOGVV(TAG, "on_subscribe_bluetooth_connections_free_request: %s", msg.dump().c_str());
877 #endif
879 #endif
880  break;
881  }
882  case 87: {
883 #ifdef USE_BLUETOOTH_PROXY
885  msg.decode(msg_data, msg_size);
886 #ifdef HAS_PROTO_MESSAGE_DUMP
887  ESP_LOGVV(TAG, "on_unsubscribe_bluetooth_le_advertisements_request: %s", msg.dump().c_str());
888 #endif
890 #endif
891  break;
892  }
893  case 89: {
894 #ifdef USE_VOICE_ASSISTANT
896  msg.decode(msg_data, msg_size);
897 #ifdef HAS_PROTO_MESSAGE_DUMP
898  ESP_LOGVV(TAG, "on_subscribe_voice_assistant_request: %s", msg.dump().c_str());
899 #endif
901 #endif
902  break;
903  }
904  case 91: {
905 #ifdef USE_VOICE_ASSISTANT
907  msg.decode(msg_data, msg_size);
908 #ifdef HAS_PROTO_MESSAGE_DUMP
909  ESP_LOGVV(TAG, "on_voice_assistant_response: %s", msg.dump().c_str());
910 #endif
911  this->on_voice_assistant_response(msg);
912 #endif
913  break;
914  }
915  case 92: {
916 #ifdef USE_VOICE_ASSISTANT
918  msg.decode(msg_data, msg_size);
919 #ifdef HAS_PROTO_MESSAGE_DUMP
920  ESP_LOGVV(TAG, "on_voice_assistant_event_response: %s", msg.dump().c_str());
921 #endif
923 #endif
924  break;
925  }
926  case 96: {
927 #ifdef USE_ALARM_CONTROL_PANEL
929  msg.decode(msg_data, msg_size);
930 #ifdef HAS_PROTO_MESSAGE_DUMP
931  ESP_LOGVV(TAG, "on_alarm_control_panel_command_request: %s", msg.dump().c_str());
932 #endif
934 #endif
935  break;
936  }
937  case 99: {
938 #ifdef USE_TEXT
939  TextCommandRequest msg;
940  msg.decode(msg_data, msg_size);
941 #ifdef HAS_PROTO_MESSAGE_DUMP
942  ESP_LOGVV(TAG, "on_text_command_request: %s", msg.dump().c_str());
943 #endif
944  this->on_text_command_request(msg);
945 #endif
946  break;
947  }
948  default:
949  return false;
950  }
951  return true;
952 }
953 
955  HelloResponse ret = this->hello(msg);
956  if (!this->send_hello_response(ret)) {
957  this->on_fatal_error();
958  }
959 }
961  ConnectResponse ret = this->connect(msg);
962  if (!this->send_connect_response(ret)) {
963  this->on_fatal_error();
964  }
965 }
967  DisconnectResponse ret = this->disconnect(msg);
968  if (!this->send_disconnect_response(ret)) {
969  this->on_fatal_error();
970  }
971 }
973  PingResponse ret = this->ping(msg);
974  if (!this->send_ping_response(ret)) {
975  this->on_fatal_error();
976  }
977 }
979  if (!this->is_connection_setup()) {
980  this->on_no_setup_connection();
981  return;
982  }
983  DeviceInfoResponse ret = this->device_info(msg);
984  if (!this->send_device_info_response(ret)) {
985  this->on_fatal_error();
986  }
987 }
989  if (!this->is_connection_setup()) {
990  this->on_no_setup_connection();
991  return;
992  }
993  if (!this->is_authenticated()) {
995  return;
996  }
997  this->list_entities(msg);
998 }
1000  if (!this->is_connection_setup()) {
1001  this->on_no_setup_connection();
1002  return;
1003  }
1004  if (!this->is_authenticated()) {
1005  this->on_unauthenticated_access();
1006  return;
1007  }
1008  this->subscribe_states(msg);
1009 }
1011  if (!this->is_connection_setup()) {
1012  this->on_no_setup_connection();
1013  return;
1014  }
1015  if (!this->is_authenticated()) {
1016  this->on_unauthenticated_access();
1017  return;
1018  }
1019  this->subscribe_logs(msg);
1020 }
1023  if (!this->is_connection_setup()) {
1024  this->on_no_setup_connection();
1025  return;
1026  }
1027  if (!this->is_authenticated()) {
1028  this->on_unauthenticated_access();
1029  return;
1030  }
1031  this->subscribe_homeassistant_services(msg);
1032 }
1034  if (!this->is_connection_setup()) {
1035  this->on_no_setup_connection();
1036  return;
1037  }
1038  if (!this->is_authenticated()) {
1039  this->on_unauthenticated_access();
1040  return;
1041  }
1042  this->subscribe_home_assistant_states(msg);
1043 }
1045  if (!this->is_connection_setup()) {
1046  this->on_no_setup_connection();
1047  return;
1048  }
1049  GetTimeResponse ret = this->get_time(msg);
1050  if (!this->send_get_time_response(ret)) {
1051  this->on_fatal_error();
1052  }
1053 }
1055  if (!this->is_connection_setup()) {
1056  this->on_no_setup_connection();
1057  return;
1058  }
1059  if (!this->is_authenticated()) {
1060  this->on_unauthenticated_access();
1061  return;
1062  }
1063  this->execute_service(msg);
1064 }
1065 #ifdef USE_COVER
1067  if (!this->is_connection_setup()) {
1068  this->on_no_setup_connection();
1069  return;
1070  }
1071  if (!this->is_authenticated()) {
1072  this->on_unauthenticated_access();
1073  return;
1074  }
1075  this->cover_command(msg);
1076 }
1077 #endif
1078 #ifdef USE_FAN
1080  if (!this->is_connection_setup()) {
1081  this->on_no_setup_connection();
1082  return;
1083  }
1084  if (!this->is_authenticated()) {
1085  this->on_unauthenticated_access();
1086  return;
1087  }
1088  this->fan_command(msg);
1089 }
1090 #endif
1091 #ifdef USE_LIGHT
1093  if (!this->is_connection_setup()) {
1094  this->on_no_setup_connection();
1095  return;
1096  }
1097  if (!this->is_authenticated()) {
1098  this->on_unauthenticated_access();
1099  return;
1100  }
1101  this->light_command(msg);
1102 }
1103 #endif
1104 #ifdef USE_SWITCH
1106  if (!this->is_connection_setup()) {
1107  this->on_no_setup_connection();
1108  return;
1109  }
1110  if (!this->is_authenticated()) {
1111  this->on_unauthenticated_access();
1112  return;
1113  }
1114  this->switch_command(msg);
1115 }
1116 #endif
1117 #ifdef USE_ESP32_CAMERA
1119  if (!this->is_connection_setup()) {
1120  this->on_no_setup_connection();
1121  return;
1122  }
1123  if (!this->is_authenticated()) {
1124  this->on_unauthenticated_access();
1125  return;
1126  }
1127  this->camera_image(msg);
1128 }
1129 #endif
1130 #ifdef USE_CLIMATE
1132  if (!this->is_connection_setup()) {
1133  this->on_no_setup_connection();
1134  return;
1135  }
1136  if (!this->is_authenticated()) {
1137  this->on_unauthenticated_access();
1138  return;
1139  }
1140  this->climate_command(msg);
1141 }
1142 #endif
1143 #ifdef USE_NUMBER
1145  if (!this->is_connection_setup()) {
1146  this->on_no_setup_connection();
1147  return;
1148  }
1149  if (!this->is_authenticated()) {
1150  this->on_unauthenticated_access();
1151  return;
1152  }
1153  this->number_command(msg);
1154 }
1155 #endif
1156 #ifdef USE_TEXT
1158  if (!this->is_connection_setup()) {
1159  this->on_no_setup_connection();
1160  return;
1161  }
1162  if (!this->is_authenticated()) {
1163  this->on_unauthenticated_access();
1164  return;
1165  }
1166  this->text_command(msg);
1167 }
1168 #endif
1169 #ifdef USE_SELECT
1171  if (!this->is_connection_setup()) {
1172  this->on_no_setup_connection();
1173  return;
1174  }
1175  if (!this->is_authenticated()) {
1176  this->on_unauthenticated_access();
1177  return;
1178  }
1179  this->select_command(msg);
1180 }
1181 #endif
1182 #ifdef USE_BUTTON
1184  if (!this->is_connection_setup()) {
1185  this->on_no_setup_connection();
1186  return;
1187  }
1188  if (!this->is_authenticated()) {
1189  this->on_unauthenticated_access();
1190  return;
1191  }
1192  this->button_command(msg);
1193 }
1194 #endif
1195 #ifdef USE_LOCK
1197  if (!this->is_connection_setup()) {
1198  this->on_no_setup_connection();
1199  return;
1200  }
1201  if (!this->is_authenticated()) {
1202  this->on_unauthenticated_access();
1203  return;
1204  }
1205  this->lock_command(msg);
1206 }
1207 #endif
1208 #ifdef USE_MEDIA_PLAYER
1210  if (!this->is_connection_setup()) {
1211  this->on_no_setup_connection();
1212  return;
1213  }
1214  if (!this->is_authenticated()) {
1215  this->on_unauthenticated_access();
1216  return;
1217  }
1218  this->media_player_command(msg);
1219 }
1220 #endif
1221 #ifdef USE_BLUETOOTH_PROXY
1224  if (!this->is_connection_setup()) {
1225  this->on_no_setup_connection();
1226  return;
1227  }
1228  if (!this->is_authenticated()) {
1229  this->on_unauthenticated_access();
1230  return;
1231  }
1232  this->subscribe_bluetooth_le_advertisements(msg);
1233 }
1234 #endif
1235 #ifdef USE_BLUETOOTH_PROXY
1237  if (!this->is_connection_setup()) {
1238  this->on_no_setup_connection();
1239  return;
1240  }
1241  if (!this->is_authenticated()) {
1242  this->on_unauthenticated_access();
1243  return;
1244  }
1245  this->bluetooth_device_request(msg);
1246 }
1247 #endif
1248 #ifdef USE_BLUETOOTH_PROXY
1250  if (!this->is_connection_setup()) {
1251  this->on_no_setup_connection();
1252  return;
1253  }
1254  if (!this->is_authenticated()) {
1255  this->on_unauthenticated_access();
1256  return;
1257  }
1258  this->bluetooth_gatt_get_services(msg);
1259 }
1260 #endif
1261 #ifdef USE_BLUETOOTH_PROXY
1263  if (!this->is_connection_setup()) {
1264  this->on_no_setup_connection();
1265  return;
1266  }
1267  if (!this->is_authenticated()) {
1268  this->on_unauthenticated_access();
1269  return;
1270  }
1271  this->bluetooth_gatt_read(msg);
1272 }
1273 #endif
1274 #ifdef USE_BLUETOOTH_PROXY
1276  if (!this->is_connection_setup()) {
1277  this->on_no_setup_connection();
1278  return;
1279  }
1280  if (!this->is_authenticated()) {
1281  this->on_unauthenticated_access();
1282  return;
1283  }
1284  this->bluetooth_gatt_write(msg);
1285 }
1286 #endif
1287 #ifdef USE_BLUETOOTH_PROXY
1289  if (!this->is_connection_setup()) {
1290  this->on_no_setup_connection();
1291  return;
1292  }
1293  if (!this->is_authenticated()) {
1294  this->on_unauthenticated_access();
1295  return;
1296  }
1297  this->bluetooth_gatt_read_descriptor(msg);
1298 }
1299 #endif
1300 #ifdef USE_BLUETOOTH_PROXY
1302  if (!this->is_connection_setup()) {
1303  this->on_no_setup_connection();
1304  return;
1305  }
1306  if (!this->is_authenticated()) {
1307  this->on_unauthenticated_access();
1308  return;
1309  }
1310  this->bluetooth_gatt_write_descriptor(msg);
1311 }
1312 #endif
1313 #ifdef USE_BLUETOOTH_PROXY
1315  if (!this->is_connection_setup()) {
1316  this->on_no_setup_connection();
1317  return;
1318  }
1319  if (!this->is_authenticated()) {
1320  this->on_unauthenticated_access();
1321  return;
1322  }
1323  this->bluetooth_gatt_notify(msg);
1324 }
1325 #endif
1326 #ifdef USE_BLUETOOTH_PROXY
1329  if (!this->is_connection_setup()) {
1330  this->on_no_setup_connection();
1331  return;
1332  }
1333  if (!this->is_authenticated()) {
1334  this->on_unauthenticated_access();
1335  return;
1336  }
1337  BluetoothConnectionsFreeResponse ret = this->subscribe_bluetooth_connections_free(msg);
1338  if (!this->send_bluetooth_connections_free_response(ret)) {
1339  this->on_fatal_error();
1340  }
1341 }
1342 #endif
1343 #ifdef USE_BLUETOOTH_PROXY
1346  if (!this->is_connection_setup()) {
1347  this->on_no_setup_connection();
1348  return;
1349  }
1350  if (!this->is_authenticated()) {
1351  this->on_unauthenticated_access();
1352  return;
1353  }
1354  this->unsubscribe_bluetooth_le_advertisements(msg);
1355 }
1356 #endif
1357 #ifdef USE_VOICE_ASSISTANT
1359  if (!this->is_connection_setup()) {
1360  this->on_no_setup_connection();
1361  return;
1362  }
1363  if (!this->is_authenticated()) {
1364  this->on_unauthenticated_access();
1365  return;
1366  }
1367  this->subscribe_voice_assistant(msg);
1368 }
1369 #endif
1370 #ifdef USE_ALARM_CONTROL_PANEL
1372  if (!this->is_connection_setup()) {
1373  this->on_no_setup_connection();
1374  return;
1375  }
1376  if (!this->is_authenticated()) {
1377  this->on_unauthenticated_access();
1378  return;
1379  }
1380  this->alarm_control_panel_command(msg);
1381 }
1382 #endif
1383 
1384 } // namespace api
1385 } // namespace esphome
void on_text_command_request(const TextCommandRequest &msg) override
bool send_list_entities_binary_sensor_response(const ListEntitiesBinarySensorResponse &msg)
void on_unsubscribe_bluetooth_le_advertisements_request(const UnsubscribeBluetoothLEAdvertisementsRequest &msg) override
virtual void on_climate_command_request(const ClimateCommandRequest &value)
virtual void on_subscribe_home_assistant_states_request(const SubscribeHomeAssistantStatesRequest &value)
bool send_fan_state_response(const FanStateResponse &msg)
bool send_ping_response(const PingResponse &msg)
virtual void on_subscribe_homeassistant_services_request(const SubscribeHomeassistantServicesRequest &value)
bool send_bluetooth_gatt_read_response(const BluetoothGATTReadResponse &msg)
virtual void on_hello_request(const HelloRequest &value)
void on_device_info_request(const DeviceInfoRequest &msg) override
bool send_text_state_response(const TextStateResponse &msg)
bool send_get_time_response(const GetTimeResponse &msg)
bool send_ping_request(const PingRequest &msg)
virtual void on_unsubscribe_bluetooth_le_advertisements_request(const UnsubscribeBluetoothLEAdvertisementsRequest &value)
void on_bluetooth_gatt_get_services_request(const BluetoothGATTGetServicesRequest &msg) override
virtual void on_bluetooth_device_request(const BluetoothDeviceRequest &value)
bool send_bluetooth_gatt_notify_data_response(const BluetoothGATTNotifyDataResponse &msg)
virtual void on_voice_assistant_response(const VoiceAssistantResponse &value)
virtual void on_no_setup_connection()=0
void on_subscribe_home_assistant_states_request(const SubscribeHomeAssistantStatesRequest &msg) override
virtual void on_ping_response(const PingResponse &value)
void on_bluetooth_gatt_write_request(const BluetoothGATTWriteRequest &msg) override
virtual void on_light_command_request(const LightCommandRequest &value)
bool send_subscribe_logs_response(const SubscribeLogsResponse &msg)
std::string dump() const
Definition: proto.cpp:84
bool send_climate_state_response(const ClimateStateResponse &msg)
bool send_binary_sensor_state_response(const BinarySensorStateResponse &msg)
void on_cover_command_request(const CoverCommandRequest &msg) override
virtual void on_fatal_error()=0
bool send_bluetooth_gatt_error_response(const BluetoothGATTErrorResponse &msg)
void on_fan_command_request(const FanCommandRequest &msg) override
void on_subscribe_homeassistant_services_request(const SubscribeHomeassistantServicesRequest &msg) override
void decode(const uint8_t *buffer, size_t length)
Definition: proto.cpp:10
bool send_list_entities_fan_response(const ListEntitiesFanResponse &msg)
bool send_number_state_response(const NumberStateResponse &msg)
virtual void on_home_assistant_state_response(const HomeAssistantStateResponse &value)
bool send_list_entities_select_response(const ListEntitiesSelectResponse &msg)
bool send_homeassistant_service_response(const HomeassistantServiceResponse &msg)
bool send_bluetooth_gatt_write_response(const BluetoothGATTWriteResponse &msg)
virtual void on_bluetooth_gatt_write_request(const BluetoothGATTWriteRequest &value)
bool send_bluetooth_device_connection_response(const BluetoothDeviceConnectionResponse &msg)
virtual void on_connect_request(const ConnectRequest &value)
bool send_list_entities_done_response(const ListEntitiesDoneResponse &msg)
bool send_device_info_response(const DeviceInfoResponse &msg)
void on_switch_command_request(const SwitchCommandRequest &msg) override
void on_bluetooth_gatt_read_descriptor_request(const BluetoothGATTReadDescriptorRequest &msg) override
void on_button_command_request(const ButtonCommandRequest &msg) override
void on_get_time_request(const GetTimeRequest &msg) override
virtual void on_subscribe_voice_assistant_request(const SubscribeVoiceAssistantRequest &value)
bool send_connect_response(const ConnectResponse &msg)
virtual void on_subscribe_bluetooth_le_advertisements_request(const SubscribeBluetoothLEAdvertisementsRequest &value)
void on_disconnect_request(const DisconnectRequest &msg) override
virtual void on_list_entities_request(const ListEntitiesRequest &value)
virtual void on_disconnect_request(const DisconnectRequest &value)
virtual void on_text_command_request(const TextCommandRequest &value)
virtual void on_select_command_request(const SelectCommandRequest &value)
virtual void on_disconnect_response(const DisconnectResponse &value)
virtual void on_bluetooth_gatt_get_services_request(const BluetoothGATTGetServicesRequest &value)
void on_ping_request(const PingRequest &msg) override
bool send_bluetooth_le_advertisement_response(const BluetoothLEAdvertisementResponse &msg)
virtual void on_camera_image_request(const CameraImageRequest &value)
bool send_list_entities_services_response(const ListEntitiesServicesResponse &msg)
virtual void on_lock_command_request(const LockCommandRequest &value)
bool send_bluetooth_gatt_get_services_response(const BluetoothGATTGetServicesResponse &msg)
void on_media_player_command_request(const MediaPlayerCommandRequest &msg) override
virtual void on_media_player_command_request(const MediaPlayerCommandRequest &value)
bool send_list_entities_text_sensor_response(const ListEntitiesTextSensorResponse &msg)
void on_subscribe_bluetooth_le_advertisements_request(const SubscribeBluetoothLEAdvertisementsRequest &msg) override
virtual void on_subscribe_bluetooth_connections_free_request(const SubscribeBluetoothConnectionsFreeRequest &value)
void on_execute_service_request(const ExecuteServiceRequest &msg) override
bool send_bluetooth_device_unpairing_response(const BluetoothDeviceUnpairingResponse &msg)
void on_connect_request(const ConnectRequest &msg) override
virtual void on_alarm_control_panel_command_request(const AlarmControlPanelCommandRequest &value)
bool send_list_entities_light_response(const ListEntitiesLightResponse &msg)
virtual void on_cover_command_request(const CoverCommandRequest &value)
bool send_text_sensor_state_response(const TextSensorStateResponse &msg)
virtual void on_voice_assistant_event_response(const VoiceAssistantEventResponse &value)
bool send_bluetooth_gatt_notify_response(const BluetoothGATTNotifyResponse &msg)
bool send_list_entities_cover_response(const ListEntitiesCoverResponse &msg)
bool send_disconnect_request(const DisconnectRequest &msg)
void on_subscribe_voice_assistant_request(const SubscribeVoiceAssistantRequest &msg) override
bool send_list_entities_camera_response(const ListEntitiesCameraResponse &msg)
bool send_list_entities_button_response(const ListEntitiesButtonResponse &msg)
bool send_list_entities_media_player_response(const ListEntitiesMediaPlayerResponse &msg)
void on_bluetooth_gatt_read_request(const BluetoothGATTReadRequest &msg) override
bool send_voice_assistant_request(const VoiceAssistantRequest &msg)
void on_subscribe_bluetooth_connections_free_request(const SubscribeBluetoothConnectionsFreeRequest &msg) override
virtual void on_execute_service_request(const ExecuteServiceRequest &value)
void on_light_command_request(const LightCommandRequest &msg) override
void on_list_entities_request(const ListEntitiesRequest &msg) override
bool send_list_entities_number_response(const ListEntitiesNumberResponse &msg)
bool send_switch_state_response(const SwitchStateResponse &msg)
bool read_message(uint32_t msg_size, uint32_t msg_type, uint8_t *msg_data) override
void on_select_command_request(const SelectCommandRequest &msg) override
void on_subscribe_logs_request(const SubscribeLogsRequest &msg) override
bool send_camera_image_response(const CameraImageResponse &msg)
bool send_list_entities_lock_response(const ListEntitiesLockResponse &msg)
void on_bluetooth_gatt_write_descriptor_request(const BluetoothGATTWriteDescriptorRequest &msg) override
bool send_list_entities_sensor_response(const ListEntitiesSensorResponse &msg)
bool send_list_entities_alarm_control_panel_response(const ListEntitiesAlarmControlPanelResponse &msg)
virtual void on_subscribe_states_request(const SubscribeStatesRequest &value)
void on_bluetooth_gatt_notify_request(const BluetoothGATTNotifyRequest &msg) override
bool send_select_state_response(const SelectStateResponse &msg)
bool send_bluetooth_connections_free_response(const BluetoothConnectionsFreeResponse &msg)
virtual void on_bluetooth_gatt_read_descriptor_request(const BluetoothGATTReadDescriptorRequest &value)
void on_subscribe_states_request(const SubscribeStatesRequest &msg) override
void on_camera_image_request(const CameraImageRequest &msg) override
virtual void on_bluetooth_gatt_write_descriptor_request(const BluetoothGATTWriteDescriptorRequest &value)
bool send_light_state_response(const LightStateResponse &msg)
virtual void on_bluetooth_gatt_notify_request(const BluetoothGATTNotifyRequest &value)
virtual void on_number_command_request(const NumberCommandRequest &value)
bool send_media_player_state_response(const MediaPlayerStateResponse &msg)
bool send_subscribe_home_assistant_state_response(const SubscribeHomeAssistantStateResponse &msg)
bool send_get_time_request(const GetTimeRequest &msg)
virtual bool is_authenticated()=0
bool send_list_entities_switch_response(const ListEntitiesSwitchResponse &msg)
virtual void on_get_time_request(const GetTimeRequest &value)
void on_alarm_control_panel_command_request(const AlarmControlPanelCommandRequest &msg) override
virtual void on_unauthenticated_access()=0
virtual void on_fan_command_request(const FanCommandRequest &value)
This is a workaround until we can figure out a way to get the tflite-micro idf component code availab...
Definition: a01nyub.cpp:7
bool send_sensor_state_response(const SensorStateResponse &msg)
bool send_cover_state_response(const CoverStateResponse &msg)
bool send_list_entities_text_response(const ListEntitiesTextResponse &msg)
bool send_hello_response(const HelloResponse &msg)
bool send_alarm_control_panel_state_response(const AlarmControlPanelStateResponse &msg)
bool send_list_entities_climate_response(const ListEntitiesClimateResponse &msg)
bool send_disconnect_response(const DisconnectResponse &msg)
void on_climate_command_request(const ClimateCommandRequest &msg) override
bool send_bluetooth_device_pairing_response(const BluetoothDevicePairingResponse &msg)
bool send_bluetooth_gatt_get_services_done_response(const BluetoothGATTGetServicesDoneResponse &msg)
virtual void on_button_command_request(const ButtonCommandRequest &value)
void on_lock_command_request(const LockCommandRequest &msg) override
bool send_lock_state_response(const LockStateResponse &msg)
bool send_bluetooth_device_clear_cache_response(const BluetoothDeviceClearCacheResponse &msg)
void on_bluetooth_device_request(const BluetoothDeviceRequest &msg) override
virtual void on_device_info_request(const DeviceInfoRequest &value)
bool send_bluetooth_le_raw_advertisements_response(const BluetoothLERawAdvertisementsResponse &msg)
virtual void on_switch_command_request(const SwitchCommandRequest &value)
virtual void on_get_time_response(const GetTimeResponse &value)
virtual void on_bluetooth_gatt_read_request(const BluetoothGATTReadRequest &value)
virtual bool is_connection_setup()=0
void on_number_command_request(const NumberCommandRequest &msg) override
virtual void on_ping_request(const PingRequest &value)
void on_hello_request(const HelloRequest &msg) override
virtual void on_subscribe_logs_request(const SubscribeLogsRequest &value)