IRIS360 PUBLIC API
  1. Entities
IRIS360 PUBLIC API
  • iris360
    • Timeseries
      • Get Timeseries
    • Entities
      • Paginate Entitites
        POST
      • Get entity latest data
        GET
    • Auth
      • Get user token
      • Refresh user token
    • Connectors
      • Out
        • Paginate Connectors
        • Update Connector Models
        • Get Connector
    • Devices
      • Paginate Devices
      • Import file
  1. Entities

Get entity latest data

Developing
GET
/api/public/v1/last-data/entities/{urn}
This endpoint returns the latest data related to this entity (Attributes). No historical information is managed in this request. Entities can have multiple properties:
Attributes: Measurement data, that can be provided by a device or be virtually managed.
Relationships: These point to other entities that somehow relate to the actual entity.
Commands: Some entities are capable of executing some commands (usually, configuration commands for real IoT devices). A command describes what kind of data can be processed by the entity.

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Path Params
urn
string 
required
Example:
urn:ngsi-ld:Device:Device001
Query Params
attrTypeFilter
array [oneOf] 
optional
Attributes are returned only when their type matches one of the specified types in the request. Allowed types are "Property", "Relationship" and "Command"
enum<string> 
optional
Property
Allowed value:
Property
enum<string> 
optional
Relationship
Allowed value:
Relationship
enum<string> 
optional
Command
Allowed value:
Command
attrNameFilter
array[string]
optional
Attributes are returned only when their name exactly matches one of the types specified in the request; partial or pattern-based matching is not supported. The values must be separated by a comma.
attrPropFilter
array[string]
optional
Functions similarly to attrNameFilter but is applied exclusively to Property attributes
attrRelFilter
array[string]
optional
Functions similarly to attrNameFilter but is applied exclusively to Relationship attributes
attrCmdFilter
array[string]
optional
Functions similarly to attrNameFilter but is applied exclusively to Command attributes
lastSent
boolean 
optional
If true, only the attributes sent in the last report will be returned
filterCmdAvailable
boolean 
optional
if true, only available Commands will be returned
filterCmdPending
boolean 
optional
if true, only pending Commands will be returned
referencedDatanesting
number 
optional
Specifies the recursion limit when searching for related data in relationships. If set to -1, the recursion is unlimited
>= -1
Header Params
tenant
string 
required
Entity tenant
Example:
OrganizationA
scope
string 
required
Entity scope
Example:
/
Body Params application/json
attrTypeFilter
array [oneOf] 
required
Attributes are returned only when their type matches one of the specified types in the request
enum<string> 
optional
Property
Allowed value:
Property
enum<string> 
optional
Relationship
Allowed value:
Relationship
enum<string> 
optional
Command
Allowed value:
Command
attrNameFilter
string 
required
Attributes are returned only when their name exactly matches one of the types specified in the request; partial or pattern-based matching is not supported. The values must be separated by a comma.
attrPropFilter
array[string]
required
Functions similarly to attrNameFilter but is applied exclusively to Property attributes
attrRelFilter
array[string]
required
Example
{
  "attrTypeFilter": [
    "Property"
  ],
  "attrNameFilter": "string",
  "attrPropFilter": [
    "string"
  ],
  "attrRelFilter": [
    "string"
  ]
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET '/api/public/v1/last-data/entities/urn:ngsi-ld:Device:Device001' \
--header 'tenant: OrganizationA' \
--header 'scope: /' \
--header 'Content-Type: application/json' \
--data-raw '{
    "attrTypeFilter": [
        "Property"
    ],
    "attrNameFilter": "string",
    "attrPropFilter": [
        "string"
    ],
    "attrRelFilter": [
        "string"
    ]
}'

Responses

🟢200Success
application/json
Body
array [oneOf] 
optional
object (EntityProperty) 
optional
id
string 
required
Entity unique id
urn
string 
required
Entity urn
tenant
string 
required
Entity tenant name
scope
string 
required
Entity scope name
name
string 
required
Attribute name
value
string  | integer  | boolean  | array  | object  | number  | null 
required
Attribute value
type
enum<string> 
required
Attribute type (Property)
Allowed value:
Property
description
string 
required
Attribute description
units
null 
required
Attribute units
timestamp
string 
required
Timestamp for the reception of the value. YYYY-MM-DD HH:MM:SS format
object (EntityRelationship) 
optional
id
string 
required
Entity unique id
urn
string 
required
Entity urn
tenant
string 
required
Entity tenant name
scope
string 
required
Entity scope name
name
string 
required
Attribute name
value
string 
required
Urn of the related entity
type
enum<string> 
required
Attribute type (Relationship)
Allowed value:
Relationship
timestamp
string 
required
Timestamp for the reception of the value. YYYY-MM-DD HH:MM:SS format
last_sent
boolean 
required
True if this timestamp is the highest among all the requested data
referenced_data
array [oneOf] 
required
The attributes of the referenced entity
pruned_by_cicle
boolean 
required
True if referenced data is empty due to a relationship cycle.
object (EntityCommand) 
optional
Example
[
  {
    "urn": "urn:ngsi-ld:Device:Device001",
    "tenant": "OrganizationA",
    "scope": "/",
    "id": "o3",
    "name": "O3",
    "value": 40.720798,
    "type": "Property",
    "description": "No info available",
    "units": "ppm",
    "timestamp": "2025-01-01 10:50:00"
  },
  {
    "urn": "urn:ngsi-ld:Device:Device001",
    "id": "cmd1",
    "name": "CMD1",
    "status": null,
    "info": null,
    "status_timestamp": null,
    "info_timestamp": null,
    "timestamp": null,
    "type": "Command",
    "available": true,
    "pending": false,
    "pending_value": null,
    "current_value": 1,
    "description": "Device sample configuration command",
    "data_type": "bool",
    "units": null,
    "max_value": null,
    "min_value": null,
    "internal": false,
    "operations": "rw"
  }
]
Modified at 2025-01-27 08:44:29
Previous
Paginate Entitites
Next
Get user token
Built with