Objects

Execute object query

Changed on

Execute object query (specialized NXSL script) and return all matching objects along with additional data fields.

post/v1/objects/query

Request

  • Base URL
    http://127.0.0.1:8000
  • URL
    http://127.0.0.1:8000/v1/objects/query
  • Auth
    HTTP bearer

Request body

fieldsstring[]

List of additional fields to be retrieved.

inputFieldsobject

Map of user input fields (available in query script via global variable $INPUT). Keys are input field names, values are user-provided values.

limitinteger

Optional limit on number of retrieved objects. Limit is applied after ordering.

orderBystring[]

List of object attributes to be used for ordering result.

querystring required

Object query script

rootObjectIdinteger

Optional root object ID to scope the query to a sub-tree. 0 (default) queries all objects.

readAllFieldsboolean

If true, all object fields are made available to the query script (default false).

Example request

{
  "query": "type == NODE"
}

Response

Query successfully executed.

fieldsobject

Changes

    • warning

      added the new Room enum value to the // response property for the response status

    • warning

      added the new CoolingZone enum value to the // response property for the response status

    • warning

      added the new Facility enum value to the // response property for the response status

    • warning

      added the new PowerDomain enum value to the // response property for the response status