Hi,
A few comments!
First of all, you don't need to use content.search when just accessing a single web map, do:
webmap = gis.content.get(itemid)
Although if you want to do it for all your maps you would do it like that:
webmaps = gis.content.search(query="", item_type="Web Map", max_items=10000)
And you don't need to use get_data to pull out the layers, as there are .layers and .basemap properties that store that info without having to pull it from the dictionary returned by get_data. I'd do something like this:
for web_map in webmaps:
print(web_map.title)
for layer in web_map.layers:
print(layer.name)
print(web_map.basemap_title)
If you want to extract all the layers in the basemap I think web_map.basemap returns these as a list that you can iterate over too.
As for checking the loading status of the layer, do you mean whether the layer is broken or not?