|
esphome-api-client 0.5.0
Modern C++17 client for the ESPHome native API (plaintext + Noise)
|
Knobs controlling a single Connection. Defaults mirror aioesphomeapi. More...
#include <connection_options.hpp>

Public Attributes | |
| std::string | client_info = "esphome-api-client" |
| Client identification reported to the device in HelloRequest. | |
| std::string | noise_psk |
| Optional pre-shared Noise key (base64, 32 bytes). Empty ⇒ plaintext. | |
| std::string | expected_name |
| Optional expected device name; if set and the device reports a different name the handshake fails (guards against connecting to the wrong host). | |
| bool | login = true |
| Send a login (AuthenticationRequest) right after HelloRequest. | |
| std::string | password |
| Optional plaintext API password (deprecated ESPHome auth). | |
| std::chrono::milliseconds | connect_timeout {30000} |
| Overall deadline for TCP connect + handshake + HelloResponse. | |
| std::chrono::milliseconds | keepalive_interval {20000} |
| How often to send a keepalive PingRequest once connected. | |
| std::chrono::milliseconds | keepalive_timeout {90000} |
| How long to wait for a PingResponse before declaring the link dead. | |
Knobs controlling a single Connection. Defaults mirror aioesphomeapi.
| std::string esphome::api::ConnectionOptions::client_info = "esphome-api-client" |
Client identification reported to the device in HelloRequest.
| std::chrono::milliseconds esphome::api::ConnectionOptions::connect_timeout {30000} |
Overall deadline for TCP connect + handshake + HelloResponse.
| std::string esphome::api::ConnectionOptions::expected_name |
Optional expected device name; if set and the device reports a different name the handshake fails (guards against connecting to the wrong host).
| std::chrono::milliseconds esphome::api::ConnectionOptions::keepalive_interval {20000} |
How often to send a keepalive PingRequest once connected.
| std::chrono::milliseconds esphome::api::ConnectionOptions::keepalive_timeout {90000} |
How long to wait for a PingResponse before declaring the link dead.
| bool esphome::api::ConnectionOptions::login = true |
Send a login (AuthenticationRequest) right after HelloRequest.
The device treats the connection as authenticated only after this; without it the device logs "requested access without authentication". Default on.
| std::string esphome::api::ConnectionOptions::noise_psk |
Optional pre-shared Noise key (base64, 32 bytes). Empty ⇒ plaintext.
| std::string esphome::api::ConnectionOptions::password |
Optional plaintext API password (deprecated ESPHome auth).
Sent in the AuthenticationRequest when login is true; empty means "no password".