I'm trying to access data from a WFS-server, E.g. https://geo.barentswatch.no/geoserver/bw/ows?
I manage to import single layers by:
uri = "https://geo.barentswatch.no/geoserver/bw/ows?srsname=EPSG:4326&typename=bw:npdsurveyongoing_latest&version=1.0.0&request=vlayer=QgsVectorLayer"
vlayer = QgsVectorLayer(uri, "bw:npdsurveyongoing_latest", "WFS")
QgsMapLayerRegistry.instance().addMapLayer(vlayer)
However, I want to import all available layers and would like them to automatically to be named by their original typeName. Seems a bit unnecessary to hardcode all names in beforehand accessing the server, but I have been struggling to figure out the codes for this.
Any way to do this in pyqgis?