**GDAL 1.x** 

GDAL versions < 2.0 have separate raster (gdal) and vector (ogr) libraries. Don't try to open the WFS vector data with GDAL, use OGR instead. GDAL supports raster data, OGR supports vector.  

**GDAL 2+** 

The raster and vector drivers are integrated into the gdal library and you use `GDALOpenEx` to open both raster and vector datasets. The ogr library/namespace is still available for backwards compatibility.

Here's a link to the [WFS Driver][1] documentation and the [OGR API tutorial][2].

  [1]: https://gdal.org/drivers/vector/wfs.html
  [2]: https://gdal.org/tutorials/vector_api_tut.html