Im a bit confused. I know how to use the esp8266 connected to an arduino where we use the arduino to send the esp AT commands it can use to connect to a wifi network and send data to a webserver on the cloud such as firebase or whatever.
Then there is the ESP8266WiFi library I have used. Now is this for uploading sketches directly to the esp only, or can the library be used for sending commands from an UNO to the esp as well?
So its either AT commands via a microcontroller to the esp, or
its sketches directly onto the esp using the esp8266WiFi library, right?
ESP8266WiFi can only be used for programming the ESP8266 directly. However, you could use it to program a custom firmware for the ESP8266 and then still connect the ESP8266 to an Uno and use whatever communications protocol you wrote into your custom ESP8266 firmware to communicate between the Uno and ESP8266. It's more convenient to use the AT firmware because it's already written for you, but writing your own firmware allows you to do whatever you like.