#include <ArduinoJson.h>
#include <MQTT.h>

#include "config.h"

class mqttHA {
  public:
    void mqtt_discovery(const String publish_topic, const String publish_payload);
    bool ConnectMQTT(const String &server, const String &name, const String &user, const String &password);
    void MessageReceived(String &topic, String &payload);
    static void SendSensorData();
    void publishTemperature(String &name, String &device_name, String &device );
    
  private:
    MQTTClient mqtt_client;
}

