WiFi.SSID() returns the SSID of the network the device is currently connected to as a char*.
WiFi.SSID()
char*