Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
podcast
Filter by Categories
Galleries
Print Category 1
Print Category 2
Uncategorized

the differences between WMS, WFS, WCS, WPS

What is the difference between WMS, WFS, WCS, WPS services?

Web Map Service – WMS

WMS (Web Map Service) is a standard protocol for serving geospatial data as images (e.g., PNG, JPEG) over the web. It allows clients to request maps and map layers from a server and display them on a map viewer or client application.

Here are a few examples of how you might call a WMS (Web Map Service) API using the curl command line tool:

# Get a map image of a specific region
curl "https://wms.example.com/maps?service=WMS&version=1.3.0&request=GetMap&layers=landcover&bbox=-180,-90,180,90&width=600&height=400&format=image/png&crs=EPSG:4326" > map.png

# Get a legend for a specific layer
curl "https://wms.example.com/maps?service=WMS&version=1.3.0&request=GetLegendGraphic&layer=landcover&format=image/png" > legend.png

# Get metadata for a specific layer
curl "https://wms.example.com/maps?service=WMS&version=1.3.0&request=GetMetadata&item=layer&layer=landcover" > metadata.xml

In these examples, wms.example.com is the URL of the WMS server, and maps is the endpoint for the WMS service. The service, version, and request parameters specify the type of request being made to the WMS server. The layers, bbox, width, height, format, and crs parameters specify the details of the map image being requested. The layer parameter is used to specify the layer for which a legend or metadata is being requested.

Web Feature Service – (WFS)

WFS (Web Feature Service) is a standard protocol for serving geospatial data as vector features (e.g., points, lines, polygons) over the web. It allows clients to request specific feature data from a server and perform operations on the data, such as querying, inserting, updating, and deleting features.

Here are a few examples of how you might call a WFS (Web Feature Service) API using the curl command line tool:

# Get a list of feature types available from the server
curl "https://wfs.example.com/features?service=WFS&version=2.0.0&request=GetCapabilities" > capabilities.xml

# Get a list of features of a specific type
curl "https://wfs.example.com/features?service=WFS&version=2.0.0&request=GetFeature&typeName=my:points&outputFormat=application/json" > features.json

# Get a single feature by ID
curl "https://wfs.example.com/features?service=WFS&version=2.0.0&request=GetFeature&typeName=my:points&featureID=point123" > feature.xml

# Insert a new feature
curl -X POST -d @newfeature.xml "https://wfs.example.com/features?service=WFS&version=2.0.0&request=InsertFeature&typeName=my:points"

# Update an existing feature
curl -X POST -d @updatefeature.xml "https://wfs.example.com/features?service=WFS&version=2.0.0&request=UpdateFeature&typeName=my:points&featureID=point123"

# Delete a feature
curl -X POST "https://wfs.example.com/features?service=WFS&version=2.0.0&request=DeleteFeature&typeName=my:points&featureID=point123"

In these examples, wfs.example.com is the URL of the WFS server, and features is the endpoint for the WFS service. The service, version, and request parameters specify the type of request being made to the WFS server. The typeName parameter specifies the feature type for which data is being requested or modified. The outputFormat parameter specifies the format in which the data should be returned. The featureID parameter specifies the ID of a specific feature to be retrieved, updated, or deleted.

Web Coverage Service – WCS

WCS (Web Coverage Service) is a standard protocol for serving geospatial data as coverages (i.e., digital representations of continuous fields of spatially varying phenomena) over the web. It allows clients to request specific coverage data from a server and perform operations on the data, such as subsetting, reprojection, and resampling.

Here are a few examples of how you might call a WCS (Web Coverage Service) API using the curl command line tool:

# Get a list of coverage offerings available from the server
curl "https://wcs.example.com/coverages?service=WCS&version=2.0.0&request=GetCapabilities" > capabilities.xml

# Get a coverage as a GeoTIFF
curl "https://wcs.example.com/coverages/mycoverage?service=WCS&version=2.0.0&request=GetCoverage&format=image/tiff" > coverage.tiff

# Get a subset of a coverage
curl "https://wcs.example.com/coverages/mycoverage?service=WCS&version=2.0.0&request=GetCoverage&format=image/tiff&subset=x(0,100)&subset=y(0,100)" > coverage_subset.tiff

# Get a reprojected and resampled coverage
curl "https://wcs.example.com/coverages/mycoverage?service=WCS&version=2.0.0&request=GetCoverage&format=image/tiff&subset=x(0,100)&subset=y(0,100)&subset=EPSG:4326" > coverage_reprojected.tiff

In these examples, wcs.example.com is the URL of the WCS server, and coverages is the endpoint for the WCS service. The service, version, and request parameters specify the type of request being made to the WCS server. The format parameter specifies the format in which the coverage data should be returned. The subset parameter is used to specify a subset of the coverage to be returned, and can include dimensions such as x, y, and time as well as a coordinate reference system (CRS) or geographic bounding box.

Web Processing Service – WPS

WPS (Web Processing Service) is a standard protocol for executing processes (i.e., algorithms or models) on geospatial data over the web. It allows clients to request the execution of specific processes on a server and receive the results of the process as output.

Here are a few examples of how you might call a WPS (Web Processing Service) API using the curl command line tool:

# Get a list of processes available from the server
curl "https://wps.example.com/processes?service=WPS&version=2.0.0&request=GetCapabilities" > capabilities.xml

# Execute a process with a simple input
curl -X POST -d "input=1234" "https://wps.example.com/processes/myprocess?service=WPS&version=2.0.0&request=Execute&response=document" > result.xml

# Execute a process with complex inputs
curl -X POST -d @inputs.xml "https://wps.example.com/processes/myprocess?service=WPS&version=2.0.0&request=Execute&response=document" > result.xml

# Get the status of a process execution
curl "https://wps.example.com/processes/myprocess?service=WPS&version=2.0.0&request=GetStatus&jobID=abc123" > status.xml

# Get the result of a process execution
curl "https://wps.example.com/processes/myprocess?service=WPS&version=2.0.0&request=GetResult&jobID=abc123" > result.xml

In these examples, wps.example.com is the URL of the WPS server, and processes is the endpoint for the WPS service. The service, version, and request parameters specify the type of request being made to the WPS server. The input parameter is used to pass a simple input value to the process, and the inputs.xml file is used to pass complex inputs in the form of an XML document. The response parameter specifies the format in which the result of the process should be returned. The jobID parameter specifies the ID of a specific process execution.

It’s important to know that the WMS, WFS, WCS, and WPS API may also support additional parameters and options, depending on the specific implementation of the service. You can refer to the documentation of the API or the capabilities document of the server to learn more about the available options.

In the context of geospatial web services such as WMS, WFS, WCS, and WPS, the GetCapabilities request is used to retrieve information about the capabilities and capabilities of the server. This information includes details such as the supported versions of the service, the available layers or feature types, the supported operations and parameters, the supported formats and CRSs, and so on.

The GetCapabilities request is typically the first request that a client makes to a server when interacting with the service. It allows the client to learn about the capabilities of the server and to determine which operations and options are available. The GetCapabilities response is usually an XML document that provides a detailed description of the capabilities of the server.

Here is an example of a GetCapabilities request for a WMS service:

curl "https://wms.example.com/maps?service=WMS&version=1.3.0&request=GetCapabilities" > capabilities.xml

In this example, the service parameter specifies that the request is for a WMS service, the version parameter specifies the version of the WMS service, and the request parameter specifies that the request is a GetCapabilities request. The response will be an XML document containing information about the capabilities of the WMS service.

Similar GetCapabilities requests can be made to WFS, WCS, and WPS services, with appropriate adjustments to the service and version parameters as needed.

Some differences between the API calls

The API calls for WMS, WFS, WCS, and WPS are different in terms of the specific parameters and options that they support, as well as the format of the request and response data.

For example, a WMS API call typically includes parameters such as service, version, request, layers, bbox, width, height, format, and crs to specify the details of the map image being requested. A WFS API call typically includes parameters such as service, version, request, typeName, outputFormat, and featureID to specify the details of the feature data being requested or modified. A WCS API call typically includes parameters such as service, version, request, coverageId, format, and subset to specify the details of the coverage data being requested. A WPS API call typically includes parameters such as service, version, request, processId, input, and response to specify the details of the process being executed.

The format of the request and response data also varies between the different web service APIs. For example, a WMS API request may include an XML document or a query string with parameters, while a WFS API request may include an XML document with a specific structure. Similarly, a WMS API response may be an image file, while a WFS API response may be an XML document or a GeoJSON file.

In summary, WMS is used for serving map images, WFS is used for serving vector features, WCS is used for serving coverages, and WPS is used for executing processes on geospatial data.