#include "theSecrets.h"
#ifdef ESP32
#include <WiFi.h>
#elif defined(ESP8266)
#include <ESP8266WiFi.h>
#endif
#include "API.hpp"
firewall::API *firewall_api;
void setup_wifi()
{
Serial.begin(115200);
WiFi.mode(WIFI_STA);
WiFi.begin(ssid, psk);
Serial.printf("Attempting to connect to WPA SSID: %s\n", ssid);
while (WiFi.status() != WL_CONNECTED)
Serial.print('.');
delay(1000);
}
Serial.println();
Serial.print("IP Address: ");
Serial.println(WiFi.localIP());
void setup()
setup_wifi();
firewall_api = new firewall::API(api_username, api_password);
void loop()
firewall_api->handle_client();