searchDevices #
Searches for device models.
Query Syntax #
HTTP #
URL: http://kuzzle:7512/_/device-manager/models/devices/_search
Method: POST
Other protocols #
{
"controller": "device-manager/models",
"action": "searchDevices",
"body": {
"query": {
// ...
},
"sort": [
// ...
]
},
// optional:
"from": "<starting offset>",
"size": "<page size>"
}
Arguments #
from
: paginates search results by defining the offset from the first result you want to fetch. Usually used with thesize
argumentsize
: set the maximum number of documents returned per result page
Body properties #
query
: the search query itself, using the ElasticSearch Query DSL.sort
: contains a list of fields, used to sort search results, in order of importance.
Response #
{
"status": 200,
"error": null,
"controller": "device-manager/models",
"action": "searchDevices",
"requestId": "<unique request identifier>",
"result": {
"hits": [
{
"_id": "<deviceModelId>",
"_source": {
// Device model content
},
},
],
"total": 42
}
}
Edit this page on Github(opens new window)