Breezoduino is a lightweight ESP8266/ESP32 library that makes sending data to Breezo instances as easy as a breeze.
Designed for resource-constrained devices, Breezoduino helps you build JSON-like payloads and handle HTTP requests without the usual overhead.
✨ Features
- Ultra-lightweight. But to clarify, we do use floats here.
- Effortless HTTP requests to servers running Breezo instance.
- Modern and readable: no
#define REQUEST_OK 1
garbage, just enums. - Plug-and-play: no complex config, just call and send. Compatibility guaranteed!*
*as long as you don't send garbage data.
TODO
Include the header:
#include <Breezoduino.h>
And also include the batteries:
using breezoduino::Breezo;
using breezoduino::TempUnit;
using breezoduino::ConcentrationUnit;
using breezoduino::ResponseStatus;
Create the client instance (can be a global variable):
Breezo client("https://breezo.site.me");
Create a request (these are all the available data types):
void setup() {
const new_request = client.newRequest();
new_request.addTemp("temp", 100.0, TempUnit::Celcius); // i live in a mysterious place
new_request.addConcentration("co2", 1000.0, ConcentrationUnit::PPM); // well i'm a plant actually
new_request.addRatio("humidity", 1.0); // HOTTT!!
}
Send it:
const result = client.send(new_request);
if (result.status == ResponseStatus.OK) {
Serial.printf("Sent request! entry ID: %s", result.id);
} else {
Serial.printf("Failed to send request! Error: ", result.message);
}
Refer to the API documentation to see what's available.