You can publish services that comply with the Open Geospatial Consortium (OGC), Web Feature Server (WFS) specification. This is an open specification for serving geographic features over the web.
Why use a WFS service?
Serving your data through a WFS service allows any application that can work with web services to access geographic features from your map or enterprise geodatabase. Unlike the OGC Web Map Service (WMS), which returns an image of a map, the WFS service returns features with geometry and attributes that clients can use in geospatial analysis. WFS services also support filters that allow you to perform spatial and attribute queries on the data.
- The WFS services you create are compliant with the WFS 1.1.0 and 2.0.0 specifications. They also support the WFS 1.0.0 specification on a read-only basis.
- WFS services use Geography Markup Language (GML) to encode the feature data. GML allows you to use XML to represent geographic information. The GML used by ArcGIS Server WFS services uses the Simple Features profile.
How to create a WFS service
You can create a WFS service from a map in ArcMap or ArcGIS Pro.
If a feature class in your map or enterprise geodatabase uses a spatial reference that cannot be represented with an EPSG (European Petroleum Survey Group) code, WGS84 is used as the spatial reference for that feature class. Feature classes in your map or enterprise geodatabase that use an unknown spatial reference system are ignored by the WFS service.
Creating a WFS service from a map
You can create a WFS service by publishing your ArcMap document to ArcGIS Server. When prompted for the capabilities you want to enable when publishing, check WFS. This creates a URL that any WFS client can use to access the service. For detailed instructions on how to create a WFS service from a map, see Tutorial: Publishing a WFS service.
The map document is just a specification of the layers that will be available in your WFS service. Symbology, query definitions, and field aliases do not transfer to the WFS service, because the purpose of the service is to expose the features in the data. To expose the visual properties of your map through OGC specifications, use a WMS service.
Remember the following items when publishing a WFS service from a map document:
If you want the WFS service to support transactions for editing (WFS-T), the source data for all the layers in the map must come from the same enterprise geodatabase and the data must be registered with the server. The map cannot contain layers from multiple sources.
The name of the layer is the type name returned from the WFS service.
If publishing the data by reference from an enterprise geodatabase, the data must be registered with the geodatabase.
Since WFS only works with features and tables, any raster layers in the map are excluded from the service.
WFS services only support simple features and do not support geodatabase functionality such as relationship classes, joins, networks, and rules.
If you use your source map document for purposes other than publishing WFS services, you may need to make a copy of the map document that will act as the source document for the WFS service. You can then alter the copy so that it meets the above requirements without affecting your original map document.
Configuring WFS service properties
A WFS service's properties are reflected in its capabilities files. When publishing a WFS service with system-generated capabilities files (the default), it is recommended that you populate the WFS service properties. For information about each WFS service property you can set, see Available WFS service properties. Additionally, the following topics include instructions on how to get to the location where you can set WFS service properties:
Setting WFS properties using an external capabilities file
Another way to define the metadata for a WFS service is by using an external capabilities file. This allows you to include additional projections for your feature types other than the defaults. The defaults include the coordinate system of the layer or feature class and WGS84 (EPSG 4326). See Use external capabilities files with WFS services for more information.
Securing WFS services
A WFS service exposes an ArcGIS Server map service to WFS consumers. The security for a WFS service is managed by controlling the security of its parent map service. If a particular role—for example, Planners—is denied access to a map, Planners will not be able to access the map through SOAP, REST, or WFS interfaces.
ArcGIS Server supports a number of authentication schemes. Services that are expected to be accessed via OGC interfaces should be secured using HTTP Basic or HTTP Digest. Most OGC clients (both Esri and third-party clients) will understand and work with these widespread standard authentication schemes.