The IoT Resource Catalogue provides a Query language for finding IoTResources. The Query language is based on xpath for querying Xml documents. The IoTResource Catalogue takes an xpath expression and applies it to the SCPD document of the IoTResources. The IoTResources that matches the xpath expression is then returned.
The xpath querying can be used directly in the REST-Url:
http://<catalogueendpoint>/<xpathexpression
Some example expressions:
http://<catalogueendpoint>//IoT:gateway – returns all IoTResource that has a gateway-element
http://<catalogueendpoint>//IoT:gateway[.=’ARMSTRONG’] – returns all IoTResource that at gateway “ARMSTRONG”
Namespaces
The following namespaces can be used in the xpath expressions:
- upnp
- IoT
- IoTObservation