yes, check this link out. If your using MQTT you don’t need to edit the library, it already is setup for it. Just call those functions and you can set a LED or something to indicate if its online or not. Not sure if this is exactly what you looking for but its what I use.